Keep allowing to pass content on document creation for use cases other than frontend app
Signed-off-by: Émile Ré <emile@getprobo.com>
This commit is contained in:
@@ -4472,7 +4472,7 @@ input DeleteVendorDataPrivacyAgreementInput {
|
||||
input CreateDocumentInput {
|
||||
organizationId: ID!
|
||||
title: String!
|
||||
content: String!
|
||||
content: String
|
||||
approverIds: [ID!]!
|
||||
documentType: DocumentType!
|
||||
classification: DocumentClassification!
|
||||
|
||||
@@ -4622,13 +4622,18 @@ func (r *mutationResolver) CreateDocument(ctx context.Context, input types.Creat
|
||||
|
||||
prb := r.ProboService(ctx, input.OrganizationID.TenantID())
|
||||
|
||||
var content string
|
||||
if input.Content != nil {
|
||||
content = *input.Content
|
||||
}
|
||||
|
||||
document, documentVersion, err := prb.Documents.Create(
|
||||
ctx,
|
||||
probo.CreateDocumentRequest{
|
||||
OrganizationID: input.OrganizationID,
|
||||
DocumentType: input.DocumentType,
|
||||
Title: input.Title,
|
||||
Content: input.Content,
|
||||
Content: content,
|
||||
ApproverIDs: input.ApproverIds,
|
||||
Classification: input.Classification,
|
||||
TrustCenterVisibility: input.TrustCenterVisibility,
|
||||
|
||||
Reference in New Issue
Block a user