Make descriptions nullable

Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
Sacha Al Himdani
2025-11-05 16:48:58 +01:00
parent 637f097cc6
commit 288c59a5f2
60 changed files with 311 additions and 375 deletions

View File

@@ -2020,7 +2020,7 @@ type VendorDataPrivacyAgreement implements Node {
type Framework implements Node {
id: ID!
name: String!
description: String!
description: String
organization: Organization! @goField(forceResolver: true)
@@ -2041,7 +2041,7 @@ type Control implements Node {
id: ID!
sectionTitle: String!
name: String!
description: String!
description: String
status: ControlStatus!
exclusionJustification: String
@@ -2089,7 +2089,7 @@ type Measure implements Node {
id: ID!
category: String!
name: String!
description: String!
description: String
state: MeasureState!
evidences(
@@ -2133,7 +2133,7 @@ type Measure implements Node {
type Task implements Node {
id: ID!
name: String!
description: String!
description: String
state: TaskState!
timeEstimate: Duration
deadline: Datetime
@@ -2161,7 +2161,7 @@ type Evidence implements Node {
type: EvidenceType!
file: File @goField(forceResolver: true)
url: String
description: String!
description: String
task: Task @goField(forceResolver: true)
measure: Measure! @goField(forceResolver: true)
@@ -2173,7 +2173,7 @@ type Evidence implements Node {
type Document implements Node {
id: ID!
title: String!
description: String!
description: String
documentType: DocumentType!
classification: DocumentClassification!
currentPublishedVersion: Int
@@ -2207,7 +2207,7 @@ type Risk implements Node {
id: ID!
snapshotId: ID
name: String!
description: String!
description: String
category: String!
treatment: RiskTreatment!
inherentLikelihood: Int!
@@ -2498,7 +2498,7 @@ type TrustCenterAccessEdge {
type TrustCenterReference implements Node {
id: ID!
name: String!
description: String!
description: String
websiteUrl: String!
logoUrl: String! @goField(forceResolver: true)
rank: Int!
@@ -3303,7 +3303,7 @@ input DeleteTrustCenterAccessInput {
input CreateTrustCenterReferenceInput {
trustCenterId: ID!
name: String!
description: String!
description: String
websiteUrl: String!
logoFile: Upload!
}
@@ -3311,7 +3311,7 @@ input CreateTrustCenterReferenceInput {
input UpdateTrustCenterReferenceInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
websiteUrl: String
logoFile: Upload
rank: Int
@@ -3464,13 +3464,13 @@ input DeletePeopleInput {
input CreateFrameworkInput {
organizationId: ID!
name: String!
description: String!
description: String
}
input UpdateFrameworkInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
}
input ImportFrameworkInput {
@@ -3489,14 +3489,14 @@ input ExportFrameworkInput {
input CreateMeasureInput {
organizationId: ID!
name: String!
description: String!
description: String
category: String!
}
input UpdateMeasureInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
category: String
state: MeasureState
}
@@ -3510,7 +3510,7 @@ input CreateTaskInput {
organizationId: ID!
measureId: ID
name: String!
description: String!
description: String
timeEstimate: Duration
assignedToId: ID
deadline: Datetime
@@ -3519,7 +3519,7 @@ input CreateTaskInput {
input UpdateTaskInput {
taskId: ID!
name: String
description: String
description: String @goField(omittable: true)
state: TaskState
timeEstimate: Duration @goField(omittable: true)
deadline: Datetime @goField(omittable: true)
@@ -3581,7 +3581,7 @@ input DeleteControlSnapshotMappingInput {
input CreateRiskInput {
organizationId: ID!
name: String!
description: String!
description: String
category: String!
ownerId: ID
treatment: RiskTreatment!
@@ -3595,7 +3595,7 @@ input CreateRiskInput {
input UpdateRiskInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
category: String
ownerId: ID @goField(omittable: true)
treatment: RiskTreatment
@@ -3644,7 +3644,7 @@ input RequestEvidenceInput {
taskId: ID!
name: String!
type: EvidenceType!
description: String!
description: String
}
input FulfillEvidenceInput {
@@ -3660,7 +3660,7 @@ input CreateEvidenceInput {
type: EvidenceType!
url: String
file: Upload
description: String!
description: String
}
input DeleteEvidenceInput {
@@ -3774,7 +3774,7 @@ input CreateControlInput {
frameworkId: ID!
sectionTitle: String!
name: String!
description: String!
description: String
status: ControlStatus!
exclusionJustification: String
}
@@ -3783,7 +3783,7 @@ input UpdateControlInput {
id: ID!
sectionTitle: String
name: String
description: String
description: String @goField(omittable: true)
status: ControlStatus
exclusionJustification: String
}

View File

@@ -11761,7 +11761,7 @@ type VendorDataPrivacyAgreement implements Node {
type Framework implements Node {
id: ID!
name: String!
description: String!
description: String
organization: Organization! @goField(forceResolver: true)
@@ -11782,7 +11782,7 @@ type Control implements Node {
id: ID!
sectionTitle: String!
name: String!
description: String!
description: String
status: ControlStatus!
exclusionJustification: String
@@ -11830,7 +11830,7 @@ type Measure implements Node {
id: ID!
category: String!
name: String!
description: String!
description: String
state: MeasureState!
evidences(
@@ -11874,7 +11874,7 @@ type Measure implements Node {
type Task implements Node {
id: ID!
name: String!
description: String!
description: String
state: TaskState!
timeEstimate: Duration
deadline: Datetime
@@ -11902,7 +11902,7 @@ type Evidence implements Node {
type: EvidenceType!
file: File @goField(forceResolver: true)
url: String
description: String!
description: String
task: Task @goField(forceResolver: true)
measure: Measure! @goField(forceResolver: true)
@@ -11914,7 +11914,7 @@ type Evidence implements Node {
type Document implements Node {
id: ID!
title: String!
description: String!
description: String
documentType: DocumentType!
classification: DocumentClassification!
currentPublishedVersion: Int
@@ -11948,7 +11948,7 @@ type Risk implements Node {
id: ID!
snapshotId: ID
name: String!
description: String!
description: String
category: String!
treatment: RiskTreatment!
inherentLikelihood: Int!
@@ -12239,7 +12239,7 @@ type TrustCenterAccessEdge {
type TrustCenterReference implements Node {
id: ID!
name: String!
description: String!
description: String
websiteUrl: String!
logoUrl: String! @goField(forceResolver: true)
rank: Int!
@@ -13044,7 +13044,7 @@ input DeleteTrustCenterAccessInput {
input CreateTrustCenterReferenceInput {
trustCenterId: ID!
name: String!
description: String!
description: String
websiteUrl: String!
logoFile: Upload!
}
@@ -13052,7 +13052,7 @@ input CreateTrustCenterReferenceInput {
input UpdateTrustCenterReferenceInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
websiteUrl: String
logoFile: Upload
rank: Int
@@ -13205,13 +13205,13 @@ input DeletePeopleInput {
input CreateFrameworkInput {
organizationId: ID!
name: String!
description: String!
description: String
}
input UpdateFrameworkInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
}
input ImportFrameworkInput {
@@ -13230,14 +13230,14 @@ input ExportFrameworkInput {
input CreateMeasureInput {
organizationId: ID!
name: String!
description: String!
description: String
category: String!
}
input UpdateMeasureInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
category: String
state: MeasureState
}
@@ -13251,7 +13251,7 @@ input CreateTaskInput {
organizationId: ID!
measureId: ID
name: String!
description: String!
description: String
timeEstimate: Duration
assignedToId: ID
deadline: Datetime
@@ -13260,7 +13260,7 @@ input CreateTaskInput {
input UpdateTaskInput {
taskId: ID!
name: String
description: String
description: String @goField(omittable: true)
state: TaskState
timeEstimate: Duration @goField(omittable: true)
deadline: Datetime @goField(omittable: true)
@@ -13322,7 +13322,7 @@ input DeleteControlSnapshotMappingInput {
input CreateRiskInput {
organizationId: ID!
name: String!
description: String!
description: String
category: String!
ownerId: ID
treatment: RiskTreatment!
@@ -13336,7 +13336,7 @@ input CreateRiskInput {
input UpdateRiskInput {
id: ID!
name: String
description: String
description: String @goField(omittable: true)
category: String
ownerId: ID @goField(omittable: true)
treatment: RiskTreatment
@@ -13385,7 +13385,7 @@ input RequestEvidenceInput {
taskId: ID!
name: String!
type: EvidenceType!
description: String!
description: String
}
input FulfillEvidenceInput {
@@ -13401,7 +13401,7 @@ input CreateEvidenceInput {
type: EvidenceType!
url: String
file: Upload
description: String!
description: String
}
input DeleteEvidenceInput {
@@ -13515,7 +13515,7 @@ input CreateControlInput {
frameworkId: ID!
sectionTitle: String!
name: String!
description: String!
description: String
status: ControlStatus!
exclusionJustification: String
}
@@ -13524,7 +13524,7 @@ input UpdateControlInput {
id: ID!
sectionTitle: String
name: String
description: String
description: String @goField(omittable: true)
status: ControlStatus
exclusionJustification: String
}
@@ -26564,14 +26564,11 @@ func (ec *executionContext) _Control_description(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Control_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -33282,14 +33279,11 @@ func (ec *executionContext) _Document_description(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Document_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -35984,14 +35978,11 @@ func (ec *executionContext) _Evidence_description(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Evidence_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -36995,14 +36986,11 @@ func (ec *executionContext) _Framework_description(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Framework_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -38889,14 +38877,11 @@ func (ec *executionContext) _Measure_description(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Measure_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -55403,14 +55388,11 @@ func (ec *executionContext) _Risk_description(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Risk_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -58991,14 +58973,11 @@ func (ec *executionContext) _Task_description(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_Task_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -62523,14 +62502,11 @@ func (ec *executionContext) _TrustCenterReference_description(ctx context.Contex
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_TrustCenterReference_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -74042,7 +74018,7 @@ func (ec *executionContext) unmarshalInputCreateControlInput(ctx context.Context
it.Name = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -74371,7 +74347,7 @@ func (ec *executionContext) unmarshalInputCreateEvidenceInput(ctx context.Contex
it.File = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -74412,7 +74388,7 @@ func (ec *executionContext) unmarshalInputCreateFrameworkInput(ctx context.Conte
it.Name = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -74453,7 +74429,7 @@ func (ec *executionContext) unmarshalInputCreateMeasureInput(ctx context.Context
it.Name = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -74964,7 +74940,7 @@ func (ec *executionContext) unmarshalInputCreateRiskInput(ctx context.Context, o
it.Name = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -75309,7 +75285,7 @@ func (ec *executionContext) unmarshalInputCreateTaskInput(ctx context.Context, o
it.Name = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -75474,7 +75450,7 @@ func (ec *executionContext) unmarshalInputCreateTrustCenterReferenceInput(ctx co
it.Name = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -78219,7 +78195,7 @@ func (ec *executionContext) unmarshalInputRequestEvidenceInput(ctx context.Conte
it.Type = data
case "description":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
data, err := ec.unmarshalNString2string(ctx, v)
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
@@ -78838,7 +78814,7 @@ func (ec *executionContext) unmarshalInputUpdateControlInput(ctx context.Context
if err != nil {
return it, err
}
it.Description = data
it.Description = graphql.OmittableOf(data)
case "status":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("status"))
data, err := ec.unmarshalOControlStatus2ᚖgoᚗproboᚗincᚋproboᚋpkgᚋcoredataᚐControlStatus(ctx, v)
@@ -79051,7 +79027,7 @@ func (ec *executionContext) unmarshalInputUpdateFrameworkInput(ctx context.Conte
if err != nil {
return it, err
}
it.Description = data
it.Description = graphql.OmittableOf(data)
}
}
@@ -79092,7 +79068,7 @@ func (ec *executionContext) unmarshalInputUpdateMeasureInput(ctx context.Context
if err != nil {
return it, err
}
it.Description = data
it.Description = graphql.OmittableOf(data)
case "category":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("category"))
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
@@ -79625,7 +79601,7 @@ func (ec *executionContext) unmarshalInputUpdateRiskInput(ctx context.Context, o
if err != nil {
return it, err
}
it.Description = data
it.Description = graphql.OmittableOf(data)
case "category":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("category"))
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
@@ -79840,7 +79816,7 @@ func (ec *executionContext) unmarshalInputUpdateTaskInput(ctx context.Context, o
if err != nil {
return it, err
}
it.Description = data
it.Description = graphql.OmittableOf(data)
case "state":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("state"))
data, err := ec.unmarshalOTaskState2ᚖgoᚗproboᚗincᚋproboᚋpkgᚋcoredataᚐTaskState(ctx, v)
@@ -80046,7 +80022,7 @@ func (ec *executionContext) unmarshalInputUpdateTrustCenterReferenceInput(ctx co
if err != nil {
return it, err
}
it.Description = data
it.Description = graphql.OmittableOf(data)
case "websiteUrl":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("websiteUrl"))
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
@@ -82585,9 +82561,6 @@ func (ec *executionContext) _Control(ctx context.Context, sel ast.SelectionSet,
}
case "description":
out.Values[i] = ec._Control_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "status":
out.Values[i] = ec._Control_status(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -86378,9 +86351,6 @@ func (ec *executionContext) _Document(ctx context.Context, sel ast.SelectionSet,
}
case "description":
out.Values[i] = ec._Document_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "documentType":
out.Values[i] = ec._Document_documentType(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -87304,9 +87274,6 @@ func (ec *executionContext) _Evidence(ctx context.Context, sel ast.SelectionSet,
out.Values[i] = ec._Evidence_url(ctx, field, obj)
case "description":
out.Values[i] = ec._Evidence_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "task":
field := field
@@ -87734,9 +87701,6 @@ func (ec *executionContext) _Framework(ctx context.Context, sel ast.SelectionSet
}
case "description":
out.Values[i] = ec._Framework_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "organization":
field := field
@@ -88542,9 +88506,6 @@ func (ec *executionContext) _Measure(ctx context.Context, sel ast.SelectionSet,
}
case "description":
out.Values[i] = ec._Measure_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "state":
out.Values[i] = ec._Measure_state(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -92617,9 +92578,6 @@ func (ec *executionContext) _Risk(ctx context.Context, sel ast.SelectionSet, obj
}
case "description":
out.Values[i] = ec._Risk_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "category":
out.Values[i] = ec._Risk_category(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -93767,9 +93725,6 @@ func (ec *executionContext) _Task(ctx context.Context, sel ast.SelectionSet, obj
}
case "description":
out.Values[i] = ec._Task_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "state":
out.Values[i] = ec._Task_state(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -95176,9 +95131,6 @@ func (ec *executionContext) _TrustCenterReference(ctx context.Context, sel ast.S
}
case "description":
out.Values[i] = ec._TrustCenterReference_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "websiteUrl":
out.Values[i] = ec._TrustCenterReference_websiteUrl(ctx, field, obj)
if out.Values[i] == graphql.Null {

View File

@@ -178,7 +178,7 @@ type Control struct {
ID gid.GID `json:"id"`
SectionTitle string `json:"sectionTitle"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Status coredata.ControlStatus `json:"status"`
ExclusionJustification *string `json:"exclusionJustification,omitempty"`
Framework *Framework `json:"framework"`
@@ -269,7 +269,7 @@ type CreateControlInput struct {
FrameworkID gid.GID `json:"frameworkId"`
SectionTitle string `json:"sectionTitle"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Status coredata.ControlStatus `json:"status"`
ExclusionJustification *string `json:"exclusionJustification,omitempty"`
}
@@ -348,7 +348,7 @@ type CreateEvidenceInput struct {
Type coredata.EvidenceType `json:"type"`
URL *string `json:"url,omitempty"`
File *graphql.Upload `json:"file,omitempty"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
}
type CreateEvidencePayload struct {
@@ -358,7 +358,7 @@ type CreateEvidencePayload struct {
type CreateFrameworkInput struct {
OrganizationID gid.GID `json:"organizationId"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
}
type CreateFrameworkPayload struct {
@@ -368,7 +368,7 @@ type CreateFrameworkPayload struct {
type CreateMeasureInput struct {
OrganizationID gid.GID `json:"organizationId"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Category string `json:"category"`
}
@@ -471,7 +471,7 @@ type CreateRiskDocumentMappingPayload struct {
type CreateRiskInput struct {
OrganizationID gid.GID `json:"organizationId"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Category string `json:"category"`
OwnerID *gid.GID `json:"ownerId,omitempty"`
Treatment coredata.RiskTreatment `json:"treatment"`
@@ -543,7 +543,7 @@ type CreateTaskInput struct {
OrganizationID gid.GID `json:"organizationId"`
MeasureID *gid.GID `json:"measureId,omitempty"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
TimeEstimate *time.Duration `json:"timeEstimate,omitempty"`
AssignedToID *gid.GID `json:"assignedToId,omitempty"`
Deadline *time.Time `json:"deadline,omitempty"`
@@ -579,7 +579,7 @@ type CreateTrustCenterFilePayload struct {
type CreateTrustCenterReferenceInput struct {
TrustCenterID gid.GID `json:"trustCenterId"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
WebsiteURL string `json:"websiteUrl"`
LogoFile graphql.Upload `json:"logoFile"`
}
@@ -1042,7 +1042,7 @@ type DisableSAMLPayload struct {
type Document struct {
ID gid.GID `json:"id"`
Title string `json:"title"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
DocumentType coredata.DocumentType `json:"documentType"`
Classification coredata.DocumentClassification `json:"classification"`
CurrentPublishedVersion *int `json:"currentPublishedVersion,omitempty"`
@@ -1148,7 +1148,7 @@ type Evidence struct {
Type coredata.EvidenceType `json:"type"`
File *File `json:"file,omitempty"`
URL *string `json:"url,omitempty"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Task *Task `json:"task,omitempty"`
Measure *Measure `json:"measure"`
CreatedAt time.Time `json:"createdAt"`
@@ -1195,7 +1195,7 @@ type File struct {
type Framework struct {
ID gid.GID `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Organization *Organization `json:"organization"`
Controls *ControlConnection `json:"controls"`
CreatedAt time.Time `json:"createdAt"`
@@ -1317,7 +1317,7 @@ type Measure struct {
ID gid.GID `json:"id"`
Category string `json:"category"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
State coredata.MeasureState `json:"state"`
Evidences *EvidenceConnection `json:"evidences"`
Tasks *TaskConnection `json:"tasks"`
@@ -1587,7 +1587,7 @@ type RequestEvidenceInput struct {
TaskID gid.GID `json:"taskId"`
Name string `json:"name"`
Type coredata.EvidenceType `json:"type"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
}
type RequestEvidencePayload struct {
@@ -1607,7 +1607,7 @@ type Risk struct {
ID gid.GID `json:"id"`
SnapshotID *gid.GID `json:"snapshotId,omitempty"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
Category string `json:"category"`
Treatment coredata.RiskTreatment `json:"treatment"`
InherentLikelihood int `json:"inherentLikelihood"`
@@ -1721,7 +1721,7 @@ type SnapshotEdge struct {
type Task struct {
ID gid.GID `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
State coredata.TaskState `json:"state"`
TimeEstimate *time.Duration `json:"timeEstimate,omitempty"`
Deadline *time.Time `json:"deadline,omitempty"`
@@ -1820,7 +1820,7 @@ type TrustCenterFileEdge struct {
type TrustCenterReference struct {
ID gid.GID `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
WebsiteURL string `json:"websiteUrl"`
LogoURL string `json:"logoUrl"`
Rank int `json:"rank"`
@@ -1887,12 +1887,12 @@ type UpdateContinualImprovementPayload struct {
}
type UpdateControlInput struct {
ID gid.GID `json:"id"`
SectionTitle *string `json:"sectionTitle,omitempty"`
Name *string `json:"name,omitempty"`
Description *string `json:"description,omitempty"`
Status *coredata.ControlStatus `json:"status,omitempty"`
ExclusionJustification *string `json:"exclusionJustification,omitempty"`
ID gid.GID `json:"id"`
SectionTitle *string `json:"sectionTitle,omitempty"`
Name *string `json:"name,omitempty"`
Description graphql.Omittable[*string] `json:"description,omitempty"`
Status *coredata.ControlStatus `json:"status,omitempty"`
ExclusionJustification *string `json:"exclusionJustification,omitempty"`
}
type UpdateControlPayload struct {
@@ -1935,9 +1935,9 @@ type UpdateDocumentVersionPayload struct {
}
type UpdateFrameworkInput struct {
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description *string `json:"description,omitempty"`
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description graphql.Omittable[*string] `json:"description,omitempty"`
}
type UpdateFrameworkPayload struct {
@@ -1945,11 +1945,11 @@ type UpdateFrameworkPayload struct {
}
type UpdateMeasureInput struct {
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description *string `json:"description,omitempty"`
Category *string `json:"category,omitempty"`
State *coredata.MeasureState `json:"state,omitempty"`
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description graphql.Omittable[*string] `json:"description,omitempty"`
Category *string `json:"category,omitempty"`
State *coredata.MeasureState `json:"state,omitempty"`
}
type UpdateMeasurePayload struct {
@@ -2048,7 +2048,7 @@ type UpdateProcessingActivityPayload struct {
type UpdateRiskInput struct {
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description *string `json:"description,omitempty"`
Description graphql.Omittable[*string] `json:"description,omitempty"`
Category *string `json:"category,omitempty"`
OwnerID graphql.Omittable[*gid.GID] `json:"ownerId,omitempty"`
Treatment *coredata.RiskTreatment `json:"treatment,omitempty"`
@@ -2087,7 +2087,7 @@ type UpdateSAMLConfigurationPayload struct {
type UpdateTaskInput struct {
TaskID gid.GID `json:"taskId"`
Name *string `json:"name,omitempty"`
Description *string `json:"description,omitempty"`
Description graphql.Omittable[*string] `json:"description,omitempty"`
State *coredata.TaskState `json:"state,omitempty"`
TimeEstimate graphql.Omittable[*time.Duration] `json:"timeEstimate,omitempty"`
Deadline graphql.Omittable[*time.Time] `json:"deadline,omitempty"`
@@ -2131,12 +2131,12 @@ type UpdateTrustCenterPayload struct {
}
type UpdateTrustCenterReferenceInput struct {
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description *string `json:"description,omitempty"`
WebsiteURL *string `json:"websiteUrl,omitempty"`
LogoFile *graphql.Upload `json:"logoFile,omitempty"`
Rank *int `json:"rank,omitempty"`
ID gid.GID `json:"id"`
Name *string `json:"name,omitempty"`
Description graphql.Omittable[*string] `json:"description,omitempty"`
WebsiteURL *string `json:"websiteUrl,omitempty"`
LogoFile *graphql.Upload `json:"logoFile,omitempty"`
Rank *int `json:"rank,omitempty"`
}
type UpdateTrustCenterReferencePayload struct {

View File

@@ -1487,7 +1487,7 @@ func (r *mutationResolver) UpdateTrustCenterReference(ctx context.Context, input
req := &probo.UpdateTrustCenterReferenceRequest{
ID: input.ID,
Name: input.Name,
Description: input.Description,
Description: UnwrapOmittable(input.Description),
WebsiteURL: input.WebsiteURL,
Rank: input.Rank,
}
@@ -1971,7 +1971,7 @@ func (r *mutationResolver) UpdateFramework(ctx context.Context, input types.Upda
framework, err := prb.Frameworks.Update(ctx, probo.UpdateFrameworkRequest{
ID: input.ID,
Name: input.Name,
Description: input.Description,
Description: UnwrapOmittable(input.Description),
})
if err != nil {
return nil, fmt.Errorf("cannot update framework: %w", err)
@@ -2096,7 +2096,7 @@ func (r *mutationResolver) UpdateControl(ctx context.Context, input types.Update
control, err := prb.Controls.Update(ctx, probo.UpdateControlRequest{
ID: input.ID,
Name: input.Name,
Description: input.Description,
Description: UnwrapOmittable(input.Description),
SectionTitle: input.SectionTitle,
Status: input.Status,
ExclusionJustification: input.ExclusionJustification,
@@ -2159,7 +2159,7 @@ func (r *mutationResolver) UpdateMeasure(ctx context.Context, input types.Update
measure, err := prb.Measures.Update(ctx, probo.UpdateMeasureRequest{
ID: input.ID,
Name: input.Name,
Description: input.Description,
Description: UnwrapOmittable(input.Description),
Category: input.Category,
State: input.State,
})
@@ -2366,7 +2366,7 @@ func (r *mutationResolver) UpdateTask(ctx context.Context, input types.UpdateTas
task, err := prb.Tasks.Update(ctx, probo.UpdateTaskRequest{
TaskID: input.TaskID,
Name: input.Name,
Description: input.Description,
Description: UnwrapOmittable(input.Description),
State: input.State,
TimeEstimate: UnwrapOmittable(input.TimeEstimate),
Deadline: UnwrapOmittable(input.Deadline),
@@ -2464,7 +2464,7 @@ func (r *mutationResolver) UpdateRisk(ctx context.Context, input types.UpdateRis
probo.UpdateRiskRequest{
ID: input.ID,
Name: input.Name,
Description: input.Description,
Description: UnwrapOmittable(input.Description),
Category: input.Category,
Treatment: input.Treatment,
OwnerID: UnwrapOmittable(input.OwnerID),

View File

@@ -461,7 +461,7 @@ type VendorEdge {
type TrustCenterReference implements Node {
id: ID!
name: String!
description: String!
description: String
websiteUrl: String!
logoUrl: String! @goField(forceResolver: true)
}

View File

@@ -1624,7 +1624,7 @@ type VendorEdge {
type TrustCenterReference implements Node {
id: ID!
name: String!
description: String!
description: String
websiteUrl: String!
logoUrl: String! @goField(forceResolver: true)
}
@@ -6809,14 +6809,11 @@ func (ec *executionContext) _TrustCenterReference_description(ctx context.Contex
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
res := resTmp.(*string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) fieldContext_TrustCenterReference_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
@@ -11683,9 +11680,6 @@ func (ec *executionContext) _TrustCenterReference(ctx context.Context, sel ast.S
}
case "description":
out.Values[i] = ec._TrustCenterReference_description(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "websiteUrl":
out.Values[i] = ec._TrustCenterReference_websiteUrl(ctx, field, obj)
if out.Values[i] == graphql.Null {

View File

@@ -220,7 +220,7 @@ type TrustCenterFileEdge struct {
type TrustCenterReference struct {
ID gid.GID `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Description *string `json:"description,omitempty"`
WebsiteURL string `json:"websiteUrl"`
LogoURL string `json:"logoUrl"`
}