@memberjunction/server 2.131.0 → 2.133.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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/server",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.133.0",
|
|
4
4
|
"description": "MemberJunction: This project provides API access via GraphQL to the common data store.",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./src/index.ts",
|
|
@@ -23,48 +23,48 @@
|
|
|
23
23
|
"@apollo/server": "^4.9.1",
|
|
24
24
|
"@graphql-tools/schema": "latest",
|
|
25
25
|
"@graphql-tools/utils": "^10.0.1",
|
|
26
|
-
"@memberjunction/actions": "2.
|
|
27
|
-
"@memberjunction/actions-apollo": "2.
|
|
28
|
-
"@memberjunction/actions-bizapps-accounting": "2.
|
|
29
|
-
"@memberjunction/actions-bizapps-crm": "2.
|
|
30
|
-
"@memberjunction/actions-bizapps-formbuilders": "2.
|
|
31
|
-
"@memberjunction/actions-bizapps-lms": "2.
|
|
32
|
-
"@memberjunction/actions-bizapps-social": "2.
|
|
33
|
-
"@memberjunction/ai": "2.
|
|
34
|
-
"@memberjunction/ai-agent-manager": "2.
|
|
35
|
-
"@memberjunction/ai-agent-manager-actions": "2.
|
|
36
|
-
"@memberjunction/ai-agents": "2.
|
|
37
|
-
"@memberjunction/ai-core-plus": "2.
|
|
38
|
-
"@memberjunction/ai-prompts": "2.
|
|
39
|
-
"@memberjunction/ai-provider-bundle": "2.
|
|
40
|
-
"@memberjunction/ai-vectors-pinecone": "2.
|
|
41
|
-
"@memberjunction/aiengine": "2.
|
|
42
|
-
"@memberjunction/communication-ms-graph": "2.
|
|
43
|
-
"@memberjunction/communication-sendgrid": "2.
|
|
44
|
-
"@memberjunction/component-registry-client-sdk": "2.
|
|
45
|
-
"@memberjunction/core": "2.
|
|
46
|
-
"@memberjunction/core-actions": "2.
|
|
47
|
-
"@memberjunction/core-entities": "2.
|
|
48
|
-
"@memberjunction/core-entities-server": "2.
|
|
49
|
-
"@memberjunction/data-context": "2.
|
|
50
|
-
"@memberjunction/data-context-server": "2.
|
|
51
|
-
"@memberjunction/doc-utils": "2.
|
|
52
|
-
"@memberjunction/encryption": "2.
|
|
53
|
-
"@memberjunction/entity-communications-server": "2.
|
|
54
|
-
"@memberjunction/external-change-detection": "2.
|
|
55
|
-
"@memberjunction/global": "2.
|
|
56
|
-
"@memberjunction/graphql-dataprovider": "2.
|
|
57
|
-
"@memberjunction/interactive-component-types": "2.
|
|
58
|
-
"@memberjunction/queue": "2.
|
|
59
|
-
"@memberjunction/scheduling-actions": "2.
|
|
60
|
-
"@memberjunction/scheduling-base-types": "2.
|
|
61
|
-
"@memberjunction/scheduling-engine": "2.
|
|
62
|
-
"@memberjunction/scheduling-engine-base": "2.
|
|
63
|
-
"@memberjunction/skip-types": "2.
|
|
64
|
-
"@memberjunction/sqlserver-dataprovider": "2.
|
|
65
|
-
"@memberjunction/storage": "2.
|
|
66
|
-
"@memberjunction/templates": "2.
|
|
67
|
-
"@memberjunction/testing-engine": "2.
|
|
26
|
+
"@memberjunction/actions": "2.133.0",
|
|
27
|
+
"@memberjunction/actions-apollo": "2.133.0",
|
|
28
|
+
"@memberjunction/actions-bizapps-accounting": "2.133.0",
|
|
29
|
+
"@memberjunction/actions-bizapps-crm": "2.133.0",
|
|
30
|
+
"@memberjunction/actions-bizapps-formbuilders": "2.133.0",
|
|
31
|
+
"@memberjunction/actions-bizapps-lms": "2.133.0",
|
|
32
|
+
"@memberjunction/actions-bizapps-social": "2.133.0",
|
|
33
|
+
"@memberjunction/ai": "2.133.0",
|
|
34
|
+
"@memberjunction/ai-agent-manager": "2.133.0",
|
|
35
|
+
"@memberjunction/ai-agent-manager-actions": "2.133.0",
|
|
36
|
+
"@memberjunction/ai-agents": "2.133.0",
|
|
37
|
+
"@memberjunction/ai-core-plus": "2.133.0",
|
|
38
|
+
"@memberjunction/ai-prompts": "2.133.0",
|
|
39
|
+
"@memberjunction/ai-provider-bundle": "2.133.0",
|
|
40
|
+
"@memberjunction/ai-vectors-pinecone": "2.133.0",
|
|
41
|
+
"@memberjunction/aiengine": "2.133.0",
|
|
42
|
+
"@memberjunction/communication-ms-graph": "2.133.0",
|
|
43
|
+
"@memberjunction/communication-sendgrid": "2.133.0",
|
|
44
|
+
"@memberjunction/component-registry-client-sdk": "2.133.0",
|
|
45
|
+
"@memberjunction/core": "2.133.0",
|
|
46
|
+
"@memberjunction/core-actions": "2.133.0",
|
|
47
|
+
"@memberjunction/core-entities": "2.133.0",
|
|
48
|
+
"@memberjunction/core-entities-server": "2.133.0",
|
|
49
|
+
"@memberjunction/data-context": "2.133.0",
|
|
50
|
+
"@memberjunction/data-context-server": "2.133.0",
|
|
51
|
+
"@memberjunction/doc-utils": "2.133.0",
|
|
52
|
+
"@memberjunction/encryption": "2.133.0",
|
|
53
|
+
"@memberjunction/entity-communications-server": "2.133.0",
|
|
54
|
+
"@memberjunction/external-change-detection": "2.133.0",
|
|
55
|
+
"@memberjunction/global": "2.133.0",
|
|
56
|
+
"@memberjunction/graphql-dataprovider": "2.133.0",
|
|
57
|
+
"@memberjunction/interactive-component-types": "2.133.0",
|
|
58
|
+
"@memberjunction/queue": "2.133.0",
|
|
59
|
+
"@memberjunction/scheduling-actions": "2.133.0",
|
|
60
|
+
"@memberjunction/scheduling-base-types": "2.133.0",
|
|
61
|
+
"@memberjunction/scheduling-engine": "2.133.0",
|
|
62
|
+
"@memberjunction/scheduling-engine-base": "2.133.0",
|
|
63
|
+
"@memberjunction/skip-types": "2.133.0",
|
|
64
|
+
"@memberjunction/sqlserver-dataprovider": "2.133.0",
|
|
65
|
+
"@memberjunction/storage": "2.133.0",
|
|
66
|
+
"@memberjunction/templates": "2.133.0",
|
|
67
|
+
"@memberjunction/testing-engine": "2.133.0",
|
|
68
68
|
"@types/compression": "^1.7.5",
|
|
69
69
|
"@types/cors": "^2.8.13",
|
|
70
70
|
"@types/jsonwebtoken": "9.0.6",
|
|
@@ -19,7 +19,7 @@ import { mj_core_schema } from '../config.js';
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
import { ActionAuthorizationEntity, ActionCategoryEntity, ActionContextTypeEntity, ActionContextEntity, ActionExecutionLogEntity, ActionFilterEntity, ActionLibraryEntity, ActionParamEntity, ActionResultCodeEntity, ActionEntity, AIActionEntity, AIAgentActionEntity, AIAgentLearningCycleEntity, AIAgentModelEntity, AIAgentNoteTypeEntity, AIAgentNoteEntity, AIAgentRequestEntity, AIAgentEntity, AIModelActionEntity, AIModelTypeEntity, AIModelEntity, AIPromptCategoryEntity, AIPromptTypeEntity, AIPromptEntity, AIResultCacheEntity, ApplicationEntityEntity, ApplicationSettingEntity, ApplicationEntity, AuditLogTypeEntity, AuditLogEntity, AuthorizationRoleEntity, AuthorizationEntity, CommunicationBaseMessageTypeEntity, CommunicationLogEntity, CommunicationProviderMessageTypeEntity, CommunicationProviderEntity, CommunicationRunEntity, CompanyEntity, CompanyIntegrationRecordMapEntity, CompanyIntegrationRunAPILogEntity, CompanyIntegrationRunDetailEntity, CompanyIntegrationRunEntity, CompanyIntegrationEntity, ContentFileTypeEntity, ContentItemAttributeEntity, ContentItemTagEntity, ContentItemEntity, ContentProcessRunEntity, ContentSourceParamEntity, ContentSourceTypeParamEntity, ContentSourceTypeEntity, ContentSourceEntity, ContentTypeAttributeEntity, ContentTypeEntity, ConversationDetailEntity, ConversationEntity, DashboardCategoryEntity, DashboardEntity, DataContextItemEntity, DataContextEntity, DatasetItemEntity, DatasetEntity, DuplicateRunDetailMatchEntity, DuplicateRunDetailEntity, DuplicateRunEntity, EmployeeCompanyIntegrationEntity, EmployeeRoleEntity, EmployeeSkillEntity, EmployeeEntity, EntityEntity, EntityActionFilterEntity, EntityActionInvocationTypeEntity, EntityActionInvocationEntity, EntityActionParamEntity, EntityActionEntity, EntityAIActionEntity, EntityCommunicationFieldEntity, EntityCommunicationMessageTypeEntity, EntityDocumentRunEntity, EntityDocumentSettingEntity, EntityDocumentTypeEntity, EntityDocumentEntity, EntityFieldValueEntity, EntityFieldEntity, EntityPermissionEntity, EntityRecordDocumentEntity, EntityRelationshipDisplayComponentEntity, EntityRelationshipEntity, EntitySettingEntity, ErrorLogEntity, ExplorerNavigationItemEntity, FileCategoryEntity, FileEntityRecordLinkEntity, FileStorageProviderEntity, FileEntity, GeneratedCodeCategoryEntity, GeneratedCodeEntity, IntegrationURLFormatEntity, IntegrationEntity, LibraryEntity, LibraryItemEntity, ListCategoryEntity, ListDetailEntity, ListEntity, AccessControlRuleEntity, AIAgentArtifactTypeEntity, AIAgentConfigurationEntity, AIAgentDataSourceEntity, AIAgentExampleEntity, AIAgentModalityEntity, AIAgentPermissionEntity, AIAgentPromptEntity, AIAgentRelationshipEntity, AIAgentRunStepEntity, AIAgentRunEntity, AIAgentStepPathEntity, AIAgentStepEntity, AIAgentTypeEntity, AIArchitectureEntity, AIConfigurationParamEntity, AIConfigurationEntity, AICredentialBindingEntity, AIModalityEntity, AIModelArchitectureEntity, AIModelCostEntity, AIModelModalityEntity, AIModelPriceTypeEntity, AIModelPriceUnitTypeEntity, AIModelVendorEntity, AIPromptModelEntity, AIPromptRunEntity, AIVendorTypeDefinitionEntity, AIVendorTypeEntity, AIVendorEntity, ArtifactPermissionEntity, ArtifactTypeEntity, ArtifactUseEntity, ArtifactVersionAttributeEntity, ArtifactVersionEntity, ArtifactEntity, CollectionArtifactEntity, CollectionPermissionEntity, CollectionEntity, ComponentDependencyEntity, ComponentLibraryEntity, ComponentLibraryLinkEntity, ComponentRegistryEntity, ComponentEntity, ConversationArtifactPermissionEntity, ConversationArtifactVersionEntity, ConversationArtifactEntity, ConversationDetailArtifactEntity, ConversationDetailAttachmentEntity, ConversationDetailRatingEntity, CredentialCategoryEntity, CredentialTypeEntity, CredentialEntity, DashboardUserPreferenceEntity, DashboardUserStateEntity, EncryptionAlgorithmEntity, EncryptionKeySourceEntity, EncryptionKeyEntity, EnvironmentEntity, ProjectEntity, PublicLinkEntity, QueryParameterEntity, RecordLinkEntity, ReportUserStateEntity, ReportVersionEntity, ScheduledJobRunEntity, ScheduledJobTypeEntity, ScheduledJobEntity, TaskDependencyEntity, TaskTypeEntity, TaskEntity, TestRubricEntity, TestRunFeedbackEntity, TestRunEntity, TestSuiteRunEntity, TestSuiteTestEntity, TestSuiteEntity, TestTypeEntity, TestEntity, UserSettingEntity, OutputDeliveryTypeEntity, OutputFormatTypeEntity, OutputTriggerTypeEntity, QueryEntity, QueryCategoryEntity, QueryEntityEntity, QueryFieldEntity, QueryPermissionEntity, QueueTaskEntity, QueueTypeEntity, QueueEntity, RecommendationItemEntity, RecommendationProviderEntity, RecommendationRunEntity, RecommendationEntity, RecordChangeReplayRunEntity, RecordChangeEntity, RecordMergeDeletionLogEntity, RecordMergeLogEntity, ReportCategoryEntity, ReportSnapshotEntity, ReportEntity, ResourceLinkEntity, ResourcePermissionEntity, ResourceTypeEntity, RoleEntity, RowLevelSecurityFilterEntity, ScheduledActionParamEntity, ScheduledActionEntity, SchemaInfoEntity, SkillEntity, TaggedItemEntity, TagEntity, TemplateCategoryEntity, TemplateContentTypeEntity, TemplateContentEntity, TemplateParamEntity, TemplateEntity, UserApplicationEntityEntity, UserApplicationEntity, UserFavoriteEntity, UserNotificationEntity, UserRecordLogEntity, UserRoleEntity, UserViewCategoryEntity, UserViewRunDetailEntity, UserViewRunEntity, UserViewEntity, UserEntity, VectorDatabaseEntity, VectorIndexEntity, VersionInstallationEntity, WorkflowEngineEntity, WorkflowRunEntity, WorkflowEntity, WorkspaceItemEntity, WorkspaceEntity } from '@memberjunction/core-entities';
|
|
22
|
+
import { ActionAuthorizationEntity, ActionCategoryEntity, ActionContextTypeEntity, ActionContextEntity, ActionExecutionLogEntity, ActionFilterEntity, ActionLibraryEntity, ActionParamEntity, ActionResultCodeEntity, ActionEntity, AIActionEntity, AIAgentActionEntity, AIAgentLearningCycleEntity, AIAgentModelEntity, AIAgentNoteTypeEntity, AIAgentNoteEntity, AIAgentRequestEntity, AIAgentEntity, AIModelActionEntity, AIModelTypeEntity, AIModelEntity, AIPromptCategoryEntity, AIPromptTypeEntity, AIPromptEntity, AIResultCacheEntity, ApplicationEntityEntity, ApplicationSettingEntity, ApplicationEntity, AuditLogTypeEntity, AuditLogEntity, AuthorizationRoleEntity, AuthorizationEntity, CommunicationBaseMessageTypeEntity, CommunicationLogEntity, CommunicationProviderMessageTypeEntity, CommunicationProviderEntity, CommunicationRunEntity, CompanyEntity, CompanyIntegrationRecordMapEntity, CompanyIntegrationRunAPILogEntity, CompanyIntegrationRunDetailEntity, CompanyIntegrationRunEntity, CompanyIntegrationEntity, ContentFileTypeEntity, ContentItemAttributeEntity, ContentItemTagEntity, ContentItemEntity, ContentProcessRunEntity, ContentSourceParamEntity, ContentSourceTypeParamEntity, ContentSourceTypeEntity, ContentSourceEntity, ContentTypeAttributeEntity, ContentTypeEntity, ConversationDetailEntity, ConversationEntity, DashboardCategoryEntity, DashboardEntity, DataContextItemEntity, DataContextEntity, DatasetItemEntity, DatasetEntity, DuplicateRunDetailMatchEntity, DuplicateRunDetailEntity, DuplicateRunEntity, EmployeeCompanyIntegrationEntity, EmployeeRoleEntity, EmployeeSkillEntity, EmployeeEntity, EntityEntity, EntityActionFilterEntity, EntityActionInvocationTypeEntity, EntityActionInvocationEntity, EntityActionParamEntity, EntityActionEntity, EntityAIActionEntity, EntityCommunicationFieldEntity, EntityCommunicationMessageTypeEntity, EntityDocumentRunEntity, EntityDocumentSettingEntity, EntityDocumentTypeEntity, EntityDocumentEntity, EntityFieldValueEntity, EntityFieldEntity, EntityPermissionEntity, EntityRecordDocumentEntity, EntityRelationshipDisplayComponentEntity, EntityRelationshipEntity, EntitySettingEntity, ErrorLogEntity, ExplorerNavigationItemEntity, FileCategoryEntity, FileEntityRecordLinkEntity, FileStorageProviderEntity, FileEntity, GeneratedCodeCategoryEntity, GeneratedCodeEntity, IntegrationURLFormatEntity, IntegrationEntity, LibraryEntity, LibraryItemEntity, ListCategoryEntity, ListDetailEntity, ListEntity, AccessControlRuleEntity, AIAgentArtifactTypeEntity, AIAgentConfigurationEntity, AIAgentDataSourceEntity, AIAgentExampleEntity, AIAgentModalityEntity, AIAgentPermissionEntity, AIAgentPromptEntity, AIAgentRelationshipEntity, AIAgentRunStepEntity, AIAgentRunEntity, AIAgentStepPathEntity, AIAgentStepEntity, AIAgentTypeEntity, AIArchitectureEntity, AIConfigurationParamEntity, AIConfigurationEntity, AICredentialBindingEntity, AIModalityEntity, AIModelArchitectureEntity, AIModelCostEntity, AIModelModalityEntity, AIModelPriceTypeEntity, AIModelPriceUnitTypeEntity, AIModelVendorEntity, AIPromptModelEntity, AIPromptRunEntity, AIVendorTypeDefinitionEntity, AIVendorTypeEntity, AIVendorEntity, ArtifactPermissionEntity, ArtifactTypeEntity, ArtifactUseEntity, ArtifactVersionAttributeEntity, ArtifactVersionEntity, ArtifactEntity, CollectionArtifactEntity, CollectionPermissionEntity, CollectionEntity, ComponentDependencyEntity, ComponentLibraryEntity, ComponentLibraryLinkEntity, ComponentRegistryEntity, ComponentEntity, ConversationArtifactPermissionEntity, ConversationArtifactVersionEntity, ConversationArtifactEntity, ConversationDetailArtifactEntity, ConversationDetailAttachmentEntity, ConversationDetailRatingEntity, CredentialCategoryEntity, CredentialTypeEntity, CredentialEntity, DashboardUserPreferenceEntity, DashboardUserStateEntity, EncryptionAlgorithmEntity, EncryptionKeySourceEntity, EncryptionKeyEntity, EnvironmentEntity, ListInvitationEntity, ListShareEntity, ProjectEntity, PublicLinkEntity, QueryParameterEntity, RecordLinkEntity, ReportUserStateEntity, ReportVersionEntity, ScheduledJobRunEntity, ScheduledJobTypeEntity, ScheduledJobEntity, TaskDependencyEntity, TaskTypeEntity, TaskEntity, TestRubricEntity, TestRunFeedbackEntity, TestRunEntity, TestSuiteRunEntity, TestSuiteTestEntity, TestSuiteEntity, TestTypeEntity, TestEntity, UserSettingEntity, OutputDeliveryTypeEntity, OutputFormatTypeEntity, OutputTriggerTypeEntity, QueryEntity, QueryCategoryEntity, QueryEntityEntity, QueryFieldEntity, QueryPermissionEntity, QueueTaskEntity, QueueTypeEntity, QueueEntity, RecommendationItemEntity, RecommendationProviderEntity, RecommendationRunEntity, RecommendationEntity, RecordChangeReplayRunEntity, RecordChangeEntity, RecordMergeDeletionLogEntity, RecordMergeLogEntity, ReportCategoryEntity, ReportSnapshotEntity, ReportEntity, ResourceLinkEntity, ResourcePermissionEntity, ResourceTypeEntity, RoleEntity, RowLevelSecurityFilterEntity, ScheduledActionParamEntity, ScheduledActionEntity, SchemaInfoEntity, SkillEntity, TaggedItemEntity, TagEntity, TemplateCategoryEntity, TemplateContentTypeEntity, TemplateContentEntity, TemplateParamEntity, TemplateEntity, UserApplicationEntityEntity, UserApplicationEntity, UserFavoriteEntity, UserNotificationEntity, UserRecordLogEntity, UserRoleEntity, UserViewCategoryEntity, UserViewRunDetailEntity, UserViewRunEntity, UserViewEntity, UserEntity, VectorDatabaseEntity, VectorIndexEntity, VersionInstallationEntity, WorkflowEngineEntity, WorkflowRunEntity, WorkflowEntity, WorkspaceItemEntity, WorkspaceEntity } from '@memberjunction/core-entities';
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
//****************************************************************************
|
|
@@ -25282,6 +25282,12 @@ export class MJList_ {
|
|
|
25282
25282
|
@Field(() => [MJDuplicateRun_])
|
|
25283
25283
|
DuplicateRuns_SourceListIDArray: MJDuplicateRun_[]; // Link to DuplicateRuns
|
|
25284
25284
|
|
|
25285
|
+
@Field(() => [MJListShare_])
|
|
25286
|
+
MJ_ListShares_ListIDArray: MJListShare_[]; // Link to MJ_ListShares
|
|
25287
|
+
|
|
25288
|
+
@Field(() => [MJListInvitation_])
|
|
25289
|
+
MJ_ListInvitations_ListIDArray: MJListInvitation_[]; // Link to MJ_ListInvitations
|
|
25290
|
+
|
|
25285
25291
|
}
|
|
25286
25292
|
|
|
25287
25293
|
//****************************************************************************
|
|
@@ -25428,6 +25434,28 @@ export class MJListResolver extends ResolverBase {
|
|
|
25428
25434
|
return result;
|
|
25429
25435
|
}
|
|
25430
25436
|
|
|
25437
|
+
@FieldResolver(() => [MJListShare_])
|
|
25438
|
+
async MJ_ListShares_ListIDArray(@Root() mjlist_: MJList_, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
25439
|
+
this.CheckUserReadPermissions('MJ: List Shares', userPayload);
|
|
25440
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
25441
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
25442
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwListShares] WHERE [ListID]='${mjlist_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: List Shares', userPayload, EntityPermissionType.Read, 'AND');
|
|
25443
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
25444
|
+
const result = await this.ArrayMapFieldNamesToCodeNames('MJ: List Shares', rows, this.GetUserFromPayload(userPayload));
|
|
25445
|
+
return result;
|
|
25446
|
+
}
|
|
25447
|
+
|
|
25448
|
+
@FieldResolver(() => [MJListInvitation_])
|
|
25449
|
+
async MJ_ListInvitations_ListIDArray(@Root() mjlist_: MJList_, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
25450
|
+
this.CheckUserReadPermissions('MJ: List Invitations', userPayload);
|
|
25451
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
25452
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
25453
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwListInvitations] WHERE [ListID]='${mjlist_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: List Invitations', userPayload, EntityPermissionType.Read, 'AND');
|
|
25454
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
25455
|
+
const result = await this.ArrayMapFieldNamesToCodeNames('MJ: List Invitations', rows, this.GetUserFromPayload(userPayload));
|
|
25456
|
+
return result;
|
|
25457
|
+
}
|
|
25458
|
+
|
|
25431
25459
|
@Mutation(() => MJList_)
|
|
25432
25460
|
async CreateMJList(
|
|
25433
25461
|
@Arg('input', () => CreateMJListInput) input: CreateMJListInput,
|
|
@@ -39995,6 +40023,388 @@ export class MJEnvironmentResolver extends ResolverBase {
|
|
|
39995
40023
|
|
|
39996
40024
|
}
|
|
39997
40025
|
|
|
40026
|
+
//****************************************************************************
|
|
40027
|
+
// ENTITY CLASS for MJ: List Invitations
|
|
40028
|
+
//****************************************************************************
|
|
40029
|
+
@ObjectType({ description: `Tracks pending invitations for users to access lists, including external users via email.` })
|
|
40030
|
+
export class MJListInvitation_ {
|
|
40031
|
+
@Field({description: `Unique identifier for the invitation.`})
|
|
40032
|
+
@MaxLength(16)
|
|
40033
|
+
ID: string;
|
|
40034
|
+
|
|
40035
|
+
@Field({description: `The list the user is being invited to.`})
|
|
40036
|
+
@MaxLength(16)
|
|
40037
|
+
ListID: string;
|
|
40038
|
+
|
|
40039
|
+
@Field({description: `Email address of the invitee.`})
|
|
40040
|
+
@MaxLength(510)
|
|
40041
|
+
Email: string;
|
|
40042
|
+
|
|
40043
|
+
@Field({description: `The role to be assigned upon acceptance (Editor or Viewer).`})
|
|
40044
|
+
@MaxLength(100)
|
|
40045
|
+
Role: string;
|
|
40046
|
+
|
|
40047
|
+
@Field({description: `Security token for validating the invitation.`})
|
|
40048
|
+
@MaxLength(200)
|
|
40049
|
+
Token: string;
|
|
40050
|
+
|
|
40051
|
+
@Field({description: `When the invitation expires.`})
|
|
40052
|
+
@MaxLength(8)
|
|
40053
|
+
ExpiresAt: Date;
|
|
40054
|
+
|
|
40055
|
+
@Field({description: `The user who created the invitation.`})
|
|
40056
|
+
@MaxLength(16)
|
|
40057
|
+
CreatedByUserID: string;
|
|
40058
|
+
|
|
40059
|
+
@Field({description: `Status of the invitation (Pending, Accepted, Expired, Revoked).`})
|
|
40060
|
+
@MaxLength(40)
|
|
40061
|
+
Status: string;
|
|
40062
|
+
|
|
40063
|
+
@Field()
|
|
40064
|
+
@MaxLength(10)
|
|
40065
|
+
_mj__CreatedAt: Date;
|
|
40066
|
+
|
|
40067
|
+
@Field()
|
|
40068
|
+
@MaxLength(10)
|
|
40069
|
+
_mj__UpdatedAt: Date;
|
|
40070
|
+
|
|
40071
|
+
@Field()
|
|
40072
|
+
@MaxLength(200)
|
|
40073
|
+
List: string;
|
|
40074
|
+
|
|
40075
|
+
@Field()
|
|
40076
|
+
@MaxLength(200)
|
|
40077
|
+
CreatedByUser: string;
|
|
40078
|
+
|
|
40079
|
+
}
|
|
40080
|
+
|
|
40081
|
+
//****************************************************************************
|
|
40082
|
+
// INPUT TYPE for MJ: List Invitations
|
|
40083
|
+
//****************************************************************************
|
|
40084
|
+
@InputType()
|
|
40085
|
+
export class CreateMJListInvitationInput {
|
|
40086
|
+
@Field({ nullable: true })
|
|
40087
|
+
ID?: string;
|
|
40088
|
+
|
|
40089
|
+
@Field({ nullable: true })
|
|
40090
|
+
ListID?: string;
|
|
40091
|
+
|
|
40092
|
+
@Field({ nullable: true })
|
|
40093
|
+
Email?: string;
|
|
40094
|
+
|
|
40095
|
+
@Field({ nullable: true })
|
|
40096
|
+
Role?: string;
|
|
40097
|
+
|
|
40098
|
+
@Field({ nullable: true })
|
|
40099
|
+
Token?: string;
|
|
40100
|
+
|
|
40101
|
+
@Field({ nullable: true })
|
|
40102
|
+
ExpiresAt?: Date;
|
|
40103
|
+
|
|
40104
|
+
@Field({ nullable: true })
|
|
40105
|
+
CreatedByUserID?: string;
|
|
40106
|
+
|
|
40107
|
+
@Field({ nullable: true })
|
|
40108
|
+
Status?: string;
|
|
40109
|
+
}
|
|
40110
|
+
|
|
40111
|
+
|
|
40112
|
+
//****************************************************************************
|
|
40113
|
+
// INPUT TYPE for MJ: List Invitations
|
|
40114
|
+
//****************************************************************************
|
|
40115
|
+
@InputType()
|
|
40116
|
+
export class UpdateMJListInvitationInput {
|
|
40117
|
+
@Field()
|
|
40118
|
+
ID: string;
|
|
40119
|
+
|
|
40120
|
+
@Field({ nullable: true })
|
|
40121
|
+
ListID?: string;
|
|
40122
|
+
|
|
40123
|
+
@Field({ nullable: true })
|
|
40124
|
+
Email?: string;
|
|
40125
|
+
|
|
40126
|
+
@Field({ nullable: true })
|
|
40127
|
+
Role?: string;
|
|
40128
|
+
|
|
40129
|
+
@Field({ nullable: true })
|
|
40130
|
+
Token?: string;
|
|
40131
|
+
|
|
40132
|
+
@Field({ nullable: true })
|
|
40133
|
+
ExpiresAt?: Date;
|
|
40134
|
+
|
|
40135
|
+
@Field({ nullable: true })
|
|
40136
|
+
CreatedByUserID?: string;
|
|
40137
|
+
|
|
40138
|
+
@Field({ nullable: true })
|
|
40139
|
+
Status?: string;
|
|
40140
|
+
|
|
40141
|
+
@Field(() => [KeyValuePairInput], { nullable: true })
|
|
40142
|
+
OldValues___?: KeyValuePairInput[];
|
|
40143
|
+
}
|
|
40144
|
+
|
|
40145
|
+
//****************************************************************************
|
|
40146
|
+
// RESOLVER for MJ: List Invitations
|
|
40147
|
+
//****************************************************************************
|
|
40148
|
+
@ObjectType()
|
|
40149
|
+
export class RunMJListInvitationViewResult {
|
|
40150
|
+
@Field(() => [MJListInvitation_])
|
|
40151
|
+
Results: MJListInvitation_[];
|
|
40152
|
+
|
|
40153
|
+
@Field(() => String, {nullable: true})
|
|
40154
|
+
UserViewRunID?: string;
|
|
40155
|
+
|
|
40156
|
+
@Field(() => Int, {nullable: true})
|
|
40157
|
+
RowCount: number;
|
|
40158
|
+
|
|
40159
|
+
@Field(() => Int, {nullable: true})
|
|
40160
|
+
TotalRowCount: number;
|
|
40161
|
+
|
|
40162
|
+
@Field(() => Int, {nullable: true})
|
|
40163
|
+
ExecutionTime: number;
|
|
40164
|
+
|
|
40165
|
+
@Field({nullable: true})
|
|
40166
|
+
ErrorMessage?: string;
|
|
40167
|
+
|
|
40168
|
+
@Field(() => Boolean, {nullable: false})
|
|
40169
|
+
Success: boolean;
|
|
40170
|
+
}
|
|
40171
|
+
|
|
40172
|
+
@Resolver(MJListInvitation_)
|
|
40173
|
+
export class MJListInvitationResolver extends ResolverBase {
|
|
40174
|
+
@Query(() => RunMJListInvitationViewResult)
|
|
40175
|
+
async RunMJListInvitationViewByID(@Arg('input', () => RunViewByIDInput) input: RunViewByIDInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40176
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40177
|
+
return super.RunViewByIDGeneric(input, provider, userPayload, pubSub);
|
|
40178
|
+
}
|
|
40179
|
+
|
|
40180
|
+
@Query(() => RunMJListInvitationViewResult)
|
|
40181
|
+
async RunMJListInvitationViewByName(@Arg('input', () => RunViewByNameInput) input: RunViewByNameInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40182
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40183
|
+
return super.RunViewByNameGeneric(input, provider, userPayload, pubSub);
|
|
40184
|
+
}
|
|
40185
|
+
|
|
40186
|
+
@Query(() => RunMJListInvitationViewResult)
|
|
40187
|
+
async RunMJListInvitationDynamicView(@Arg('input', () => RunDynamicViewInput) input: RunDynamicViewInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40188
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40189
|
+
input.EntityName = 'MJ: List Invitations';
|
|
40190
|
+
return super.RunDynamicViewGeneric(input, provider, userPayload, pubSub);
|
|
40191
|
+
}
|
|
40192
|
+
@Query(() => MJListInvitation_, { nullable: true })
|
|
40193
|
+
async MJListInvitation(@Arg('ID', () => String) ID: string, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine): Promise<MJListInvitation_ | null> {
|
|
40194
|
+
this.CheckUserReadPermissions('MJ: List Invitations', userPayload);
|
|
40195
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40196
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
40197
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwListInvitations] WHERE [ID]='${ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: List Invitations', userPayload, EntityPermissionType.Read, 'AND');
|
|
40198
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
40199
|
+
const result = await this.MapFieldNamesToCodeNames('MJ: List Invitations', rows && rows.length > 0 ? rows[0] : {}, this.GetUserFromPayload(userPayload));
|
|
40200
|
+
return result;
|
|
40201
|
+
}
|
|
40202
|
+
|
|
40203
|
+
@Mutation(() => MJListInvitation_)
|
|
40204
|
+
async CreateMJListInvitation(
|
|
40205
|
+
@Arg('input', () => CreateMJListInvitationInput) input: CreateMJListInvitationInput,
|
|
40206
|
+
@Ctx() { providers, userPayload }: AppContext,
|
|
40207
|
+
@PubSub() pubSub: PubSubEngine
|
|
40208
|
+
) {
|
|
40209
|
+
const provider = GetReadWriteProvider(providers);
|
|
40210
|
+
return this.CreateRecord('MJ: List Invitations', input, provider, userPayload, pubSub)
|
|
40211
|
+
}
|
|
40212
|
+
|
|
40213
|
+
@Mutation(() => MJListInvitation_)
|
|
40214
|
+
async UpdateMJListInvitation(
|
|
40215
|
+
@Arg('input', () => UpdateMJListInvitationInput) input: UpdateMJListInvitationInput,
|
|
40216
|
+
@Ctx() { providers, userPayload }: AppContext,
|
|
40217
|
+
@PubSub() pubSub: PubSubEngine
|
|
40218
|
+
) {
|
|
40219
|
+
const provider = GetReadWriteProvider(providers);
|
|
40220
|
+
return this.UpdateRecord('MJ: List Invitations', input, provider, userPayload, pubSub);
|
|
40221
|
+
}
|
|
40222
|
+
|
|
40223
|
+
@Mutation(() => MJListInvitation_)
|
|
40224
|
+
async DeleteMJListInvitation(@Arg('ID', () => String) ID: string, @Arg('options___', () => DeleteOptionsInput) options: DeleteOptionsInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40225
|
+
const provider = GetReadWriteProvider(providers);
|
|
40226
|
+
const key = new CompositeKey([{FieldName: 'ID', Value: ID}]);
|
|
40227
|
+
return this.DeleteRecord('MJ: List Invitations', key, options, provider, userPayload, pubSub);
|
|
40228
|
+
}
|
|
40229
|
+
|
|
40230
|
+
}
|
|
40231
|
+
|
|
40232
|
+
//****************************************************************************
|
|
40233
|
+
// ENTITY CLASS for MJ: List Shares
|
|
40234
|
+
//****************************************************************************
|
|
40235
|
+
@ObjectType({ description: `Manages user access and permissions for shared lists.` })
|
|
40236
|
+
export class MJListShare_ {
|
|
40237
|
+
@Field({description: `Unique identifier for the share record.`})
|
|
40238
|
+
@MaxLength(16)
|
|
40239
|
+
ID: string;
|
|
40240
|
+
|
|
40241
|
+
@Field({description: `The list being shared.`})
|
|
40242
|
+
@MaxLength(16)
|
|
40243
|
+
ListID: string;
|
|
40244
|
+
|
|
40245
|
+
@Field({description: `The user receiving access to the list.`})
|
|
40246
|
+
@MaxLength(16)
|
|
40247
|
+
UserID: string;
|
|
40248
|
+
|
|
40249
|
+
@Field({description: `The permission level granted (Editor or Viewer).`})
|
|
40250
|
+
@MaxLength(100)
|
|
40251
|
+
Role: string;
|
|
40252
|
+
|
|
40253
|
+
@Field({description: `Current status of the share (Active or Pending).`})
|
|
40254
|
+
@MaxLength(40)
|
|
40255
|
+
Status: string;
|
|
40256
|
+
|
|
40257
|
+
@Field()
|
|
40258
|
+
@MaxLength(10)
|
|
40259
|
+
_mj__CreatedAt: Date;
|
|
40260
|
+
|
|
40261
|
+
@Field()
|
|
40262
|
+
@MaxLength(10)
|
|
40263
|
+
_mj__UpdatedAt: Date;
|
|
40264
|
+
|
|
40265
|
+
@Field()
|
|
40266
|
+
@MaxLength(200)
|
|
40267
|
+
List: string;
|
|
40268
|
+
|
|
40269
|
+
@Field()
|
|
40270
|
+
@MaxLength(200)
|
|
40271
|
+
User: string;
|
|
40272
|
+
|
|
40273
|
+
}
|
|
40274
|
+
|
|
40275
|
+
//****************************************************************************
|
|
40276
|
+
// INPUT TYPE for MJ: List Shares
|
|
40277
|
+
//****************************************************************************
|
|
40278
|
+
@InputType()
|
|
40279
|
+
export class CreateMJListShareInput {
|
|
40280
|
+
@Field({ nullable: true })
|
|
40281
|
+
ID?: string;
|
|
40282
|
+
|
|
40283
|
+
@Field({ nullable: true })
|
|
40284
|
+
ListID?: string;
|
|
40285
|
+
|
|
40286
|
+
@Field({ nullable: true })
|
|
40287
|
+
UserID?: string;
|
|
40288
|
+
|
|
40289
|
+
@Field({ nullable: true })
|
|
40290
|
+
Role?: string;
|
|
40291
|
+
|
|
40292
|
+
@Field({ nullable: true })
|
|
40293
|
+
Status?: string;
|
|
40294
|
+
}
|
|
40295
|
+
|
|
40296
|
+
|
|
40297
|
+
//****************************************************************************
|
|
40298
|
+
// INPUT TYPE for MJ: List Shares
|
|
40299
|
+
//****************************************************************************
|
|
40300
|
+
@InputType()
|
|
40301
|
+
export class UpdateMJListShareInput {
|
|
40302
|
+
@Field()
|
|
40303
|
+
ID: string;
|
|
40304
|
+
|
|
40305
|
+
@Field({ nullable: true })
|
|
40306
|
+
ListID?: string;
|
|
40307
|
+
|
|
40308
|
+
@Field({ nullable: true })
|
|
40309
|
+
UserID?: string;
|
|
40310
|
+
|
|
40311
|
+
@Field({ nullable: true })
|
|
40312
|
+
Role?: string;
|
|
40313
|
+
|
|
40314
|
+
@Field({ nullable: true })
|
|
40315
|
+
Status?: string;
|
|
40316
|
+
|
|
40317
|
+
@Field(() => [KeyValuePairInput], { nullable: true })
|
|
40318
|
+
OldValues___?: KeyValuePairInput[];
|
|
40319
|
+
}
|
|
40320
|
+
|
|
40321
|
+
//****************************************************************************
|
|
40322
|
+
// RESOLVER for MJ: List Shares
|
|
40323
|
+
//****************************************************************************
|
|
40324
|
+
@ObjectType()
|
|
40325
|
+
export class RunMJListShareViewResult {
|
|
40326
|
+
@Field(() => [MJListShare_])
|
|
40327
|
+
Results: MJListShare_[];
|
|
40328
|
+
|
|
40329
|
+
@Field(() => String, {nullable: true})
|
|
40330
|
+
UserViewRunID?: string;
|
|
40331
|
+
|
|
40332
|
+
@Field(() => Int, {nullable: true})
|
|
40333
|
+
RowCount: number;
|
|
40334
|
+
|
|
40335
|
+
@Field(() => Int, {nullable: true})
|
|
40336
|
+
TotalRowCount: number;
|
|
40337
|
+
|
|
40338
|
+
@Field(() => Int, {nullable: true})
|
|
40339
|
+
ExecutionTime: number;
|
|
40340
|
+
|
|
40341
|
+
@Field({nullable: true})
|
|
40342
|
+
ErrorMessage?: string;
|
|
40343
|
+
|
|
40344
|
+
@Field(() => Boolean, {nullable: false})
|
|
40345
|
+
Success: boolean;
|
|
40346
|
+
}
|
|
40347
|
+
|
|
40348
|
+
@Resolver(MJListShare_)
|
|
40349
|
+
export class MJListShareResolver extends ResolverBase {
|
|
40350
|
+
@Query(() => RunMJListShareViewResult)
|
|
40351
|
+
async RunMJListShareViewByID(@Arg('input', () => RunViewByIDInput) input: RunViewByIDInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40352
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40353
|
+
return super.RunViewByIDGeneric(input, provider, userPayload, pubSub);
|
|
40354
|
+
}
|
|
40355
|
+
|
|
40356
|
+
@Query(() => RunMJListShareViewResult)
|
|
40357
|
+
async RunMJListShareViewByName(@Arg('input', () => RunViewByNameInput) input: RunViewByNameInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40358
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40359
|
+
return super.RunViewByNameGeneric(input, provider, userPayload, pubSub);
|
|
40360
|
+
}
|
|
40361
|
+
|
|
40362
|
+
@Query(() => RunMJListShareViewResult)
|
|
40363
|
+
async RunMJListShareDynamicView(@Arg('input', () => RunDynamicViewInput) input: RunDynamicViewInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40364
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40365
|
+
input.EntityName = 'MJ: List Shares';
|
|
40366
|
+
return super.RunDynamicViewGeneric(input, provider, userPayload, pubSub);
|
|
40367
|
+
}
|
|
40368
|
+
@Query(() => MJListShare_, { nullable: true })
|
|
40369
|
+
async MJListShare(@Arg('ID', () => String) ID: string, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine): Promise<MJListShare_ | null> {
|
|
40370
|
+
this.CheckUserReadPermissions('MJ: List Shares', userPayload);
|
|
40371
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
40372
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
40373
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwListShares] WHERE [ID]='${ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: List Shares', userPayload, EntityPermissionType.Read, 'AND');
|
|
40374
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
40375
|
+
const result = await this.MapFieldNamesToCodeNames('MJ: List Shares', rows && rows.length > 0 ? rows[0] : {}, this.GetUserFromPayload(userPayload));
|
|
40376
|
+
return result;
|
|
40377
|
+
}
|
|
40378
|
+
|
|
40379
|
+
@Mutation(() => MJListShare_)
|
|
40380
|
+
async CreateMJListShare(
|
|
40381
|
+
@Arg('input', () => CreateMJListShareInput) input: CreateMJListShareInput,
|
|
40382
|
+
@Ctx() { providers, userPayload }: AppContext,
|
|
40383
|
+
@PubSub() pubSub: PubSubEngine
|
|
40384
|
+
) {
|
|
40385
|
+
const provider = GetReadWriteProvider(providers);
|
|
40386
|
+
return this.CreateRecord('MJ: List Shares', input, provider, userPayload, pubSub)
|
|
40387
|
+
}
|
|
40388
|
+
|
|
40389
|
+
@Mutation(() => MJListShare_)
|
|
40390
|
+
async UpdateMJListShare(
|
|
40391
|
+
@Arg('input', () => UpdateMJListShareInput) input: UpdateMJListShareInput,
|
|
40392
|
+
@Ctx() { providers, userPayload }: AppContext,
|
|
40393
|
+
@PubSub() pubSub: PubSubEngine
|
|
40394
|
+
) {
|
|
40395
|
+
const provider = GetReadWriteProvider(providers);
|
|
40396
|
+
return this.UpdateRecord('MJ: List Shares', input, provider, userPayload, pubSub);
|
|
40397
|
+
}
|
|
40398
|
+
|
|
40399
|
+
@Mutation(() => MJListShare_)
|
|
40400
|
+
async DeleteMJListShare(@Arg('ID', () => String) ID: string, @Arg('options___', () => DeleteOptionsInput) options: DeleteOptionsInput, @Ctx() { providers, userPayload }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
40401
|
+
const provider = GetReadWriteProvider(providers);
|
|
40402
|
+
const key = new CompositeKey([{FieldName: 'ID', Value: ID}]);
|
|
40403
|
+
return this.DeleteRecord('MJ: List Shares', key, options, provider, userPayload, pubSub);
|
|
40404
|
+
}
|
|
40405
|
+
|
|
40406
|
+
}
|
|
40407
|
+
|
|
39998
40408
|
//****************************************************************************
|
|
39999
40409
|
// ENTITY CLASS for MJ: Projects
|
|
40000
40410
|
//****************************************************************************
|
|
@@ -55582,6 +55992,12 @@ export class MJUser_ {
|
|
|
55582
55992
|
@Field(() => [MJUserSetting_])
|
|
55583
55993
|
MJ_UserSettings_UserIDArray: MJUserSetting_[]; // Link to MJ_UserSettings
|
|
55584
55994
|
|
|
55995
|
+
@Field(() => [MJListInvitation_])
|
|
55996
|
+
MJ_ListInvitations_CreatedByUserIDArray: MJListInvitation_[]; // Link to MJ_ListInvitations
|
|
55997
|
+
|
|
55998
|
+
@Field(() => [MJListShare_])
|
|
55999
|
+
MJ_ListShares_UserIDArray: MJListShare_[]; // Link to MJ_ListShares
|
|
56000
|
+
|
|
55585
56001
|
@Field(() => [MJResourcePermission_])
|
|
55586
56002
|
ResourcePermissions_UserIDArray: MJResourcePermission_[]; // Link to ResourcePermissions
|
|
55587
56003
|
|
|
@@ -56329,6 +56745,28 @@ export class MJUserResolverBase extends ResolverBase {
|
|
|
56329
56745
|
return result;
|
|
56330
56746
|
}
|
|
56331
56747
|
|
|
56748
|
+
@FieldResolver(() => [MJListInvitation_])
|
|
56749
|
+
async MJ_ListInvitations_CreatedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
56750
|
+
this.CheckUserReadPermissions('MJ: List Invitations', userPayload);
|
|
56751
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
56752
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
56753
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwListInvitations] WHERE [CreatedByUserID]='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: List Invitations', userPayload, EntityPermissionType.Read, 'AND');
|
|
56754
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
56755
|
+
const result = await this.ArrayMapFieldNamesToCodeNames('MJ: List Invitations', rows, this.GetUserFromPayload(userPayload));
|
|
56756
|
+
return result;
|
|
56757
|
+
}
|
|
56758
|
+
|
|
56759
|
+
@FieldResolver(() => [MJListShare_])
|
|
56760
|
+
async MJ_ListShares_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
56761
|
+
this.CheckUserReadPermissions('MJ: List Shares', userPayload);
|
|
56762
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
56763
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
56764
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwListShares] WHERE [UserID]='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: List Shares', userPayload, EntityPermissionType.Read, 'AND');
|
|
56765
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
56766
|
+
const result = await this.ArrayMapFieldNamesToCodeNames('MJ: List Shares', rows, this.GetUserFromPayload(userPayload));
|
|
56767
|
+
return result;
|
|
56768
|
+
}
|
|
56769
|
+
|
|
56332
56770
|
@FieldResolver(() => [MJResourcePermission_])
|
|
56333
56771
|
async ResourcePermissions_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { dataSources, userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
|
|
56334
56772
|
this.CheckUserReadPermissions('Resource Permissions', userPayload);
|