Replace presigned URL string fields (logoUrl, fileUrl, ndaFileName, etc.) with nested File references resolved through /api/files/v1/. Update console Relay queries and e2e coverage accordingly. Route NDA upload through filemanager.PutFile and return stable IAM org logo URLs for consistency with the files API. Signed-off-by: Ludovic Vielle <ludovic@probo.com>
107 lines
2.4 KiB
GraphQL
107 lines
2.4 KiB
GraphQL
enum FrameworkOrderField
|
|
@goModel(model: "go.probo.inc/probo/pkg/coredata.FrameworkOrderField") {
|
|
CREATED_AT
|
|
@goEnum(
|
|
value: "go.probo.inc/probo/pkg/coredata.FrameworkOrderFieldCreatedAt"
|
|
)
|
|
}
|
|
|
|
input FrameworkOrder
|
|
@goModel(
|
|
model: "go.probo.inc/probo/pkg/server/api/console/v1/types.FrameworkOrderBy"
|
|
) {
|
|
direction: OrderDirection!
|
|
field: FrameworkOrderField!
|
|
}
|
|
|
|
type Framework implements Node {
|
|
id: ID!
|
|
name: String!
|
|
description: String
|
|
|
|
organization: Organization! @goField(forceResolver: true)
|
|
|
|
controls(
|
|
first: Int
|
|
after: CursorKey
|
|
last: Int
|
|
before: CursorKey
|
|
orderBy: ControlOrder
|
|
filter: ControlFilter
|
|
): ControlConnection! @goField(forceResolver: true)
|
|
lightLogo: File @goField(forceResolver: true)
|
|
darkLogo: File @goField(forceResolver: true)
|
|
|
|
createdAt: Datetime!
|
|
updatedAt: Datetime!
|
|
|
|
permission(action: String!): Boolean! @goField(forceResolver: true)
|
|
}
|
|
|
|
type FrameworkConnection
|
|
@goModel(
|
|
model: "go.probo.inc/probo/pkg/server/api/console/v1/types.FrameworkConnection"
|
|
) {
|
|
totalCount: Int! @goField(forceResolver: true)
|
|
edges: [FrameworkEdge!]!
|
|
pageInfo: PageInfo!
|
|
}
|
|
|
|
type FrameworkEdge {
|
|
cursor: CursorKey!
|
|
node: Framework!
|
|
}
|
|
|
|
extend type Mutation {
|
|
createFramework(input: CreateFrameworkInput!): CreateFrameworkPayload!
|
|
updateFramework(input: UpdateFrameworkInput!): UpdateFrameworkPayload!
|
|
importFramework(input: ImportFrameworkInput!): ImportFrameworkPayload!
|
|
deleteFramework(input: DeleteFrameworkInput!): DeleteFrameworkPayload!
|
|
exportFramework(input: ExportFrameworkInput!): ExportFrameworkPayload!
|
|
}
|
|
|
|
input CreateFrameworkInput {
|
|
organizationId: ID!
|
|
name: String!
|
|
description: String
|
|
}
|
|
|
|
input UpdateFrameworkInput {
|
|
id: ID!
|
|
name: String
|
|
description: String @goField(omittable: true)
|
|
}
|
|
|
|
input ImportFrameworkInput {
|
|
organizationId: ID!
|
|
file: Upload!
|
|
}
|
|
|
|
input DeleteFrameworkInput {
|
|
frameworkId: ID!
|
|
}
|
|
|
|
input ExportFrameworkInput {
|
|
frameworkId: ID!
|
|
}
|
|
|
|
type CreateFrameworkPayload {
|
|
frameworkEdge: FrameworkEdge!
|
|
}
|
|
|
|
type UpdateFrameworkPayload {
|
|
framework: Framework!
|
|
}
|
|
|
|
type ImportFrameworkPayload {
|
|
frameworkEdge: FrameworkEdge!
|
|
}
|
|
|
|
type DeleteFrameworkPayload {
|
|
deletedFrameworkId: ID!
|
|
}
|
|
|
|
type ExportFrameworkPayload {
|
|
exportJobId: ID!
|
|
}
|