Add fields to organization
Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/**
|
/**
|
||||||
* @generated SignedSource<<6f19d3ea0d16b3f4418e85261e3e4915>>
|
* @generated SignedSource<<148c6dc2b419fa0611529004e0a3535a>>
|
||||||
* @lightSyntaxTransform
|
* @lightSyntaxTransform
|
||||||
* @nogrep
|
* @nogrep
|
||||||
*/
|
*/
|
||||||
@@ -54,14 +54,21 @@ v3 = {
|
|||||||
"name": "name",
|
"name": "name",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
},
|
},
|
||||||
v4 = [
|
v4 = {
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "email",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
v5 = [
|
||||||
{
|
{
|
||||||
"kind": "Literal",
|
"kind": "Literal",
|
||||||
"name": "first",
|
"name": "first",
|
||||||
"value": 100
|
"value": 100
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
v5 = {
|
v6 = {
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"args": null,
|
"args": null,
|
||||||
"kind": "ScalarField",
|
"kind": "ScalarField",
|
||||||
@@ -139,7 +146,29 @@ return {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"args": (v4/*: any*/),
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "description",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "websiteUrl",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
(v4/*: any*/),
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "headquarterAddress",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": (v5/*: any*/),
|
||||||
"concreteType": "UserConnection",
|
"concreteType": "UserConnection",
|
||||||
"kind": "LinkedField",
|
"kind": "LinkedField",
|
||||||
"name": "users",
|
"name": "users",
|
||||||
@@ -169,14 +198,8 @@ return {
|
|||||||
"name": "fullName",
|
"name": "fullName",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
},
|
},
|
||||||
{
|
(v4/*: any*/),
|
||||||
"alias": null,
|
(v6/*: any*/)
|
||||||
"args": null,
|
|
||||||
"kind": "ScalarField",
|
|
||||||
"name": "email",
|
|
||||||
"storageKey": null
|
|
||||||
},
|
|
||||||
(v5/*: any*/)
|
|
||||||
],
|
],
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
}
|
}
|
||||||
@@ -188,7 +211,7 @@ return {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"args": (v4/*: any*/),
|
"args": (v5/*: any*/),
|
||||||
"concreteType": "ConnectorConnection",
|
"concreteType": "ConnectorConnection",
|
||||||
"kind": "LinkedField",
|
"kind": "LinkedField",
|
||||||
"name": "connectors",
|
"name": "connectors",
|
||||||
@@ -219,7 +242,7 @@ return {
|
|||||||
"name": "type",
|
"name": "type",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
},
|
},
|
||||||
(v5/*: any*/)
|
(v6/*: any*/)
|
||||||
],
|
],
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
}
|
}
|
||||||
@@ -239,12 +262,12 @@ return {
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"params": {
|
"params": {
|
||||||
"cacheID": "3062be33ff59b816b10d098c083db370",
|
"cacheID": "c19271fc733cfb1de051ccdd98ae9bef",
|
||||||
"id": null,
|
"id": null,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"name": "OrganizationGraph_ViewQuery",
|
"name": "OrganizationGraph_ViewQuery",
|
||||||
"operationKind": "query",
|
"operationKind": "query",
|
||||||
"text": "query OrganizationGraph_ViewQuery(\n $organizationId: ID!\n) {\n node(id: $organizationId) {\n __typename\n ... on Organization {\n id\n name\n ...SettingsPageFragment\n }\n id\n }\n}\n\nfragment SettingsPageFragment on Organization {\n id\n name\n logoUrl\n users(first: 100) {\n edges {\n node {\n id\n fullName\n email\n createdAt\n }\n }\n }\n connectors(first: 100) {\n edges {\n node {\n id\n name\n type\n createdAt\n }\n }\n }\n}\n"
|
"text": "query OrganizationGraph_ViewQuery(\n $organizationId: ID!\n) {\n node(id: $organizationId) {\n __typename\n ... on Organization {\n id\n name\n ...SettingsPageFragment\n }\n id\n }\n}\n\nfragment SettingsPageFragment on Organization {\n id\n name\n logoUrl\n description\n websiteUrl\n email\n headquarterAddress\n users(first: 100) {\n edges {\n node {\n id\n fullName\n email\n createdAt\n }\n }\n }\n connectors(first: 100) {\n edges {\n node {\n id\n name\n type\n createdAt\n }\n }\n }\n}\n"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|||||||
@@ -180,6 +180,10 @@ const TRUST_CENTER_QUERY = `
|
|||||||
id
|
id
|
||||||
name
|
name
|
||||||
logoUrl
|
logoUrl
|
||||||
|
description
|
||||||
|
websiteUrl
|
||||||
|
email
|
||||||
|
headquarterAddress
|
||||||
}
|
}
|
||||||
documents(first: 100) {
|
documents(first: 100) {
|
||||||
edges {
|
edges {
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ import {
|
|||||||
Label,
|
Label,
|
||||||
PageHeader,
|
PageHeader,
|
||||||
Spinner,
|
Spinner,
|
||||||
|
Textarea,
|
||||||
useConfirm,
|
useConfirm,
|
||||||
useToast,
|
useToast,
|
||||||
} from "@probo/ui";
|
} from "@probo/ui";
|
||||||
@@ -19,14 +20,15 @@ import type { PreloadedQuery } from "react-relay";
|
|||||||
import type { OrganizationGraph_ViewQuery } from "/hooks/graph/__generated__/OrganizationGraph_ViewQuery.graphql";
|
import type { OrganizationGraph_ViewQuery } from "/hooks/graph/__generated__/OrganizationGraph_ViewQuery.graphql";
|
||||||
import { useFragment, useMutation, usePreloadedQuery } from "react-relay";
|
import { useFragment, useMutation, usePreloadedQuery } from "react-relay";
|
||||||
import { organizationViewQuery } from "/hooks/graph/OrganizationGraph";
|
import { organizationViewQuery } from "/hooks/graph/OrganizationGraph";
|
||||||
import { useDebounceCallback } from "usehooks-ts";
|
|
||||||
import { graphql } from "relay-runtime";
|
import { graphql } from "relay-runtime";
|
||||||
import type {
|
import type {
|
||||||
SettingsPageFragment$data,
|
SettingsPageFragment$data,
|
||||||
SettingsPageFragment$key,
|
SettingsPageFragment$key,
|
||||||
} from "./__generated__/SettingsPageFragment.graphql";
|
} from "./__generated__/SettingsPageFragment.graphql";
|
||||||
import { useState, type ChangeEventHandler } from "react";
|
import { useState, type ChangeEventHandler, useEffect } from "react";
|
||||||
import { sprintf } from "@probo/helpers";
|
import { sprintf } from "@probo/helpers";
|
||||||
|
import { useFormWithSchema } from "/hooks/useFormWithSchema";
|
||||||
|
import { z } from "zod";
|
||||||
import type { NodeOf } from "/types";
|
import type { NodeOf } from "/types";
|
||||||
import clsx from "clsx";
|
import clsx from "clsx";
|
||||||
import { useMutationWithToasts } from "/hooks/useMutationWithToasts";
|
import { useMutationWithToasts } from "/hooks/useMutationWithToasts";
|
||||||
@@ -36,6 +38,16 @@ import { useDeleteOrganizationMutation } from "/hooks/graph/OrganizationGraph";
|
|||||||
import { useNavigate } from "react-router";
|
import { useNavigate } from "react-router";
|
||||||
import { DeleteOrganizationDialog } from "/components/organizations/DeleteOrganizationDialog";
|
import { DeleteOrganizationDialog } from "/components/organizations/DeleteOrganizationDialog";
|
||||||
|
|
||||||
|
const organizationSchema = z.object({
|
||||||
|
name: z.string().min(1, "Organization name is required"),
|
||||||
|
description: z.string().optional(),
|
||||||
|
websiteUrl: z.string().optional(),
|
||||||
|
email: z.string().optional(),
|
||||||
|
headquarterAddress: z.string().optional(),
|
||||||
|
});
|
||||||
|
|
||||||
|
type OrganizationFormData = z.infer<typeof organizationSchema>;
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
queryRef: PreloadedQuery<OrganizationGraph_ViewQuery>;
|
queryRef: PreloadedQuery<OrganizationGraph_ViewQuery>;
|
||||||
};
|
};
|
||||||
@@ -45,6 +57,10 @@ const organizationFragment = graphql`
|
|||||||
id
|
id
|
||||||
name
|
name
|
||||||
logoUrl
|
logoUrl
|
||||||
|
description
|
||||||
|
websiteUrl
|
||||||
|
email
|
||||||
|
headquarterAddress
|
||||||
users(first: 100) {
|
users(first: 100) {
|
||||||
edges {
|
edges {
|
||||||
node {
|
node {
|
||||||
@@ -75,6 +91,10 @@ const updateOrganizationMutation = graphql`
|
|||||||
id
|
id
|
||||||
name
|
name
|
||||||
logoUrl
|
logoUrl
|
||||||
|
description
|
||||||
|
websiteUrl
|
||||||
|
email
|
||||||
|
headquarterAddress
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -92,25 +112,59 @@ export default function SettingsPage({ queryRef }: Props) {
|
|||||||
organizationFragment,
|
organizationFragment,
|
||||||
organizationKey
|
organizationKey
|
||||||
);
|
);
|
||||||
const [updateOrganization, isUpdating] = useMutation(
|
const [updateOrganization] = useMutation(updateOrganizationMutation);
|
||||||
updateOrganizationMutation
|
|
||||||
);
|
|
||||||
const [deleteOrganization, isDeleting] = useDeleteOrganizationMutation();
|
const [deleteOrganization, isDeleting] = useDeleteOrganizationMutation();
|
||||||
const users = organization.users.edges.map((edge) => edge.node);
|
const users = organization.users.edges.map((edge) => edge.node);
|
||||||
|
|
||||||
const updateOrganizationName = useDebounceCallback((name: string) => {
|
const { formState, handleSubmit, register, reset } =
|
||||||
if (!name) {
|
useFormWithSchema(organizationSchema, {
|
||||||
return "";
|
defaultValues: {
|
||||||
}
|
name: organization.name || "",
|
||||||
|
description: organization.description || "",
|
||||||
|
websiteUrl: organization.websiteUrl || "",
|
||||||
|
email: organization.email || "",
|
||||||
|
headquarterAddress: organization.headquarterAddress || "",
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
reset({
|
||||||
|
name: organization.name || "",
|
||||||
|
description: organization.description || "",
|
||||||
|
websiteUrl: organization.websiteUrl || "",
|
||||||
|
email: organization.email || "",
|
||||||
|
headquarterAddress: organization.headquarterAddress || "",
|
||||||
|
});
|
||||||
|
}, [organization, reset]);
|
||||||
|
|
||||||
|
const onSubmit = handleSubmit((data: OrganizationFormData) => {
|
||||||
updateOrganization({
|
updateOrganization({
|
||||||
variables: {
|
variables: {
|
||||||
input: {
|
input: {
|
||||||
organizationId: organization.id,
|
organizationId: organization.id,
|
||||||
name,
|
name: data.name,
|
||||||
|
description: data.description || null,
|
||||||
|
websiteUrl: data.websiteUrl || null,
|
||||||
|
email: data.email || null,
|
||||||
|
headquarterAddress: data.headquarterAddress || null,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
onError(error) {
|
||||||
|
toast({
|
||||||
|
title: __("Failed to update organization"),
|
||||||
|
description: error.message || __("Please try again."),
|
||||||
|
variant: "error",
|
||||||
|
});
|
||||||
|
},
|
||||||
|
onCompleted() {
|
||||||
|
toast({
|
||||||
|
title: __("Organization updated"),
|
||||||
|
description: __("Your organization details have been updated successfully."),
|
||||||
|
variant: "success",
|
||||||
|
});
|
||||||
|
},
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}, 500);
|
|
||||||
|
|
||||||
const updateOrganizationLogo: ChangeEventHandler<HTMLInputElement> = (e) => {
|
const updateOrganizationLogo: ChangeEventHandler<HTMLInputElement> = (e) => {
|
||||||
const file = e.target.files?.[0];
|
const file = e.target.files?.[0];
|
||||||
@@ -156,12 +210,13 @@ export default function SettingsPage({ queryRef }: Props) {
|
|||||||
<PageHeader title={__("Settings")} />
|
<PageHeader title={__("Settings")} />
|
||||||
|
|
||||||
{/* Organization settings */}
|
{/* Organization settings */}
|
||||||
|
<form onSubmit={onSubmit} className="space-y-6">
|
||||||
<div className="space-y-4">
|
<div className="space-y-4">
|
||||||
<div className="flex items-center justify-between">
|
<div className="flex items-center justify-between">
|
||||||
<h2 className="text-base font-medium">
|
<h2 className="text-base font-medium">
|
||||||
{__("Organization details")}
|
{__("Organization details")}
|
||||||
</h2>
|
</h2>
|
||||||
{isUpdating && <Spinner />}
|
{formState.isSubmitting && <Spinner />}
|
||||||
</div>
|
</div>
|
||||||
<Card padded className="space-y-4">
|
<Card padded className="space-y-4">
|
||||||
<div>
|
<div>
|
||||||
@@ -173,7 +228,7 @@ export default function SettingsPage({ queryRef }: Props) {
|
|||||||
size="xl"
|
size="xl"
|
||||||
/>
|
/>
|
||||||
<FileButton
|
<FileButton
|
||||||
disabled={isUpdating}
|
disabled={formState.isSubmitting}
|
||||||
onChange={updateOrganizationLogo}
|
onChange={updateOrganizationLogo}
|
||||||
variant="secondary"
|
variant="secondary"
|
||||||
className="ml-auto"
|
className="ml-auto"
|
||||||
@@ -183,16 +238,62 @@ export default function SettingsPage({ queryRef }: Props) {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<Field
|
<Field
|
||||||
readOnly={isUpdating}
|
{...register("name")}
|
||||||
|
readOnly={formState.isSubmitting}
|
||||||
name="name"
|
name="name"
|
||||||
type="text"
|
type="text"
|
||||||
defaultValue={organization.name}
|
|
||||||
label={__("Organization name")}
|
label={__("Organization name")}
|
||||||
placeholder={__("Organization name")}
|
placeholder={__("Organization name")}
|
||||||
onChange={(e) => updateOrganizationName(e.currentTarget.value)}
|
|
||||||
/>
|
/>
|
||||||
|
<div>
|
||||||
|
<Label>{__("Description")}</Label>
|
||||||
|
<Textarea
|
||||||
|
{...register("description")}
|
||||||
|
readOnly={formState.isSubmitting}
|
||||||
|
name="description"
|
||||||
|
placeholder={__("Brief description of your organization")}
|
||||||
|
rows={3}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
<div className="grid grid-cols-1 md:grid-cols-2 gap-4">
|
||||||
|
<Field
|
||||||
|
{...register("websiteUrl")}
|
||||||
|
readOnly={formState.isSubmitting}
|
||||||
|
name="websiteUrl"
|
||||||
|
type="url"
|
||||||
|
label={__("Website URL")}
|
||||||
|
placeholder={__("https://example.com")}
|
||||||
|
/>
|
||||||
|
<Field
|
||||||
|
{...register("email")}
|
||||||
|
readOnly={formState.isSubmitting}
|
||||||
|
name="email"
|
||||||
|
type="email"
|
||||||
|
label={__("Email")}
|
||||||
|
placeholder={__("contact@example.com")}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<Label>{__("Headquarter Address")}</Label>
|
||||||
|
<Textarea
|
||||||
|
{...register("headquarterAddress")}
|
||||||
|
readOnly={formState.isSubmitting}
|
||||||
|
name="headquarterAddress"
|
||||||
|
placeholder={__("123 Main St, City, Country")}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
{formState.isDirty && (
|
||||||
|
<div className="flex justify-end pt-6">
|
||||||
|
<Button type="submit" disabled={formState.isSubmitting}>
|
||||||
|
{formState.isSubmitting ? __("Updating...") : __("Update Organization")}
|
||||||
|
</Button>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</Card>
|
</Card>
|
||||||
</div>
|
</div>
|
||||||
|
</form>
|
||||||
|
|
||||||
{/* Integrations */}
|
{/* Integrations */}
|
||||||
<div className="space-y-4">
|
<div className="space-y-4">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/**
|
/**
|
||||||
* @generated SignedSource<<e5b6c1db04175ebddb21379dfd331fc6>>
|
* @generated SignedSource<<c071187d5ef9cecb128621c57f97393b>>
|
||||||
* @lightSyntaxTransform
|
* @lightSyntaxTransform
|
||||||
* @nogrep
|
* @nogrep
|
||||||
*/
|
*/
|
||||||
@@ -21,6 +21,9 @@ export type SettingsPageFragment$data = {
|
|||||||
};
|
};
|
||||||
}>;
|
}>;
|
||||||
};
|
};
|
||||||
|
readonly description: string | null | undefined;
|
||||||
|
readonly email: string | null | undefined;
|
||||||
|
readonly headquarterAddress: string | null | undefined;
|
||||||
readonly id: string;
|
readonly id: string;
|
||||||
readonly logoUrl: string | null | undefined;
|
readonly logoUrl: string | null | undefined;
|
||||||
readonly name: string;
|
readonly name: string;
|
||||||
@@ -34,6 +37,7 @@ export type SettingsPageFragment$data = {
|
|||||||
};
|
};
|
||||||
}>;
|
}>;
|
||||||
};
|
};
|
||||||
|
readonly websiteUrl: string | null | undefined;
|
||||||
readonly " $fragmentType": "SettingsPageFragment";
|
readonly " $fragmentType": "SettingsPageFragment";
|
||||||
};
|
};
|
||||||
export type SettingsPageFragment$key = {
|
export type SettingsPageFragment$key = {
|
||||||
@@ -56,14 +60,21 @@ v1 = {
|
|||||||
"name": "name",
|
"name": "name",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
},
|
},
|
||||||
v2 = [
|
v2 = {
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "email",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
v3 = [
|
||||||
{
|
{
|
||||||
"kind": "Literal",
|
"kind": "Literal",
|
||||||
"name": "first",
|
"name": "first",
|
||||||
"value": 100
|
"value": 100
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
v3 = {
|
v4 = {
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"args": null,
|
"args": null,
|
||||||
"kind": "ScalarField",
|
"kind": "ScalarField",
|
||||||
@@ -87,7 +98,29 @@ return {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"args": (v2/*: any*/),
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "description",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "websiteUrl",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
(v2/*: any*/),
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "headquarterAddress",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": (v3/*: any*/),
|
||||||
"concreteType": "UserConnection",
|
"concreteType": "UserConnection",
|
||||||
"kind": "LinkedField",
|
"kind": "LinkedField",
|
||||||
"name": "users",
|
"name": "users",
|
||||||
@@ -117,14 +150,8 @@ return {
|
|||||||
"name": "fullName",
|
"name": "fullName",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
},
|
},
|
||||||
{
|
(v2/*: any*/),
|
||||||
"alias": null,
|
(v4/*: any*/)
|
||||||
"args": null,
|
|
||||||
"kind": "ScalarField",
|
|
||||||
"name": "email",
|
|
||||||
"storageKey": null
|
|
||||||
},
|
|
||||||
(v3/*: any*/)
|
|
||||||
],
|
],
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
}
|
}
|
||||||
@@ -136,7 +163,7 @@ return {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"alias": null,
|
"alias": null,
|
||||||
"args": (v2/*: any*/),
|
"args": (v3/*: any*/),
|
||||||
"concreteType": "ConnectorConnection",
|
"concreteType": "ConnectorConnection",
|
||||||
"kind": "LinkedField",
|
"kind": "LinkedField",
|
||||||
"name": "connectors",
|
"name": "connectors",
|
||||||
@@ -167,7 +194,7 @@ return {
|
|||||||
"name": "type",
|
"name": "type",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
},
|
},
|
||||||
(v3/*: any*/)
|
(v4/*: any*/)
|
||||||
],
|
],
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
}
|
}
|
||||||
@@ -183,6 +210,6 @@ return {
|
|||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
(node as any).hash = "b7ee53afcaaa0406dceeda0427afdfef";
|
(node as any).hash = "bdd548b7b3fa4c1cfef32569dc63d45d";
|
||||||
|
|
||||||
export default node;
|
export default node;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/**
|
/**
|
||||||
* @generated SignedSource<<6dc30c35c9ce7367967d235b1a259179>>
|
* @generated SignedSource<<892a78db951d547b53d595d219b94e75>>
|
||||||
* @lightSyntaxTransform
|
* @lightSyntaxTransform
|
||||||
* @nogrep
|
* @nogrep
|
||||||
*/
|
*/
|
||||||
@@ -10,9 +10,13 @@
|
|||||||
|
|
||||||
import { ConcreteRequest } from 'relay-runtime';
|
import { ConcreteRequest } from 'relay-runtime';
|
||||||
export type UpdateOrganizationInput = {
|
export type UpdateOrganizationInput = {
|
||||||
|
description?: string | null | undefined;
|
||||||
|
email?: string | null | undefined;
|
||||||
|
headquarterAddress?: string | null | undefined;
|
||||||
logo?: any | null | undefined;
|
logo?: any | null | undefined;
|
||||||
name?: string | null | undefined;
|
name?: string | null | undefined;
|
||||||
organizationId: string;
|
organizationId: string;
|
||||||
|
websiteUrl?: string | null | undefined;
|
||||||
};
|
};
|
||||||
export type SettingsPage_UpdateMutation$variables = {
|
export type SettingsPage_UpdateMutation$variables = {
|
||||||
input: UpdateOrganizationInput;
|
input: UpdateOrganizationInput;
|
||||||
@@ -20,9 +24,13 @@ export type SettingsPage_UpdateMutation$variables = {
|
|||||||
export type SettingsPage_UpdateMutation$data = {
|
export type SettingsPage_UpdateMutation$data = {
|
||||||
readonly updateOrganization: {
|
readonly updateOrganization: {
|
||||||
readonly organization: {
|
readonly organization: {
|
||||||
|
readonly description: string | null | undefined;
|
||||||
|
readonly email: string | null | undefined;
|
||||||
|
readonly headquarterAddress: string | null | undefined;
|
||||||
readonly id: string;
|
readonly id: string;
|
||||||
readonly logoUrl: string | null | undefined;
|
readonly logoUrl: string | null | undefined;
|
||||||
readonly name: string;
|
readonly name: string;
|
||||||
|
readonly websiteUrl: string | null | undefined;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -82,6 +90,34 @@ v1 = [
|
|||||||
"kind": "ScalarField",
|
"kind": "ScalarField",
|
||||||
"name": "logoUrl",
|
"name": "logoUrl",
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "description",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "websiteUrl",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "email",
|
||||||
|
"storageKey": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"alias": null,
|
||||||
|
"args": null,
|
||||||
|
"kind": "ScalarField",
|
||||||
|
"name": "headquarterAddress",
|
||||||
|
"storageKey": null
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"storageKey": null
|
"storageKey": null
|
||||||
@@ -108,16 +144,16 @@ return {
|
|||||||
"selections": (v1/*: any*/)
|
"selections": (v1/*: any*/)
|
||||||
},
|
},
|
||||||
"params": {
|
"params": {
|
||||||
"cacheID": "ac8d86332fabe20dd7ea8fef4207b75e",
|
"cacheID": "3526d270f311db33e0563abc99c96978",
|
||||||
"id": null,
|
"id": null,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"name": "SettingsPage_UpdateMutation",
|
"name": "SettingsPage_UpdateMutation",
|
||||||
"operationKind": "mutation",
|
"operationKind": "mutation",
|
||||||
"text": "mutation SettingsPage_UpdateMutation(\n $input: UpdateOrganizationInput!\n) {\n updateOrganization(input: $input) {\n organization {\n id\n name\n logoUrl\n }\n }\n}\n"
|
"text": "mutation SettingsPage_UpdateMutation(\n $input: UpdateOrganizationInput!\n) {\n updateOrganization(input: $input) {\n organization {\n id\n name\n logoUrl\n description\n websiteUrl\n email\n headquarterAddress\n }\n }\n}\n"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
(node as any).hash = "85f76939223253c1d102d05cd74f7538";
|
(node as any).hash = "54949158defa7f1bb8e1e578db7cd7be";
|
||||||
|
|
||||||
export default node;
|
export default node;
|
||||||
|
|||||||
5
pkg/coredata/migrations/20250919T121111Z.sql
Normal file
5
pkg/coredata/migrations/20250919T121111Z.sql
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
ALTER TABLE organizations
|
||||||
|
ADD COLUMN description TEXT,
|
||||||
|
ADD COLUMN website_url TEXT,
|
||||||
|
ADD COLUMN email CITEXT,
|
||||||
|
ADD COLUMN headquarter_address TEXT;
|
||||||
@@ -32,6 +32,10 @@ type (
|
|||||||
TenantID gid.TenantID `db:"tenant_id"`
|
TenantID gid.TenantID `db:"tenant_id"`
|
||||||
Name string `db:"name"`
|
Name string `db:"name"`
|
||||||
LogoObjectKey string `db:"logo_object_key"`
|
LogoObjectKey string `db:"logo_object_key"`
|
||||||
|
Description *string `db:"description"`
|
||||||
|
WebsiteURL *string `db:"website_url"`
|
||||||
|
Email *string `db:"email"`
|
||||||
|
HeadquarterAddress *string `db:"headquarter_address"`
|
||||||
CreatedAt time.Time `db:"created_at"`
|
CreatedAt time.Time `db:"created_at"`
|
||||||
UpdatedAt time.Time `db:"updated_at"`
|
UpdatedAt time.Time `db:"updated_at"`
|
||||||
}
|
}
|
||||||
@@ -64,6 +68,10 @@ SELECT
|
|||||||
id,
|
id,
|
||||||
name,
|
name,
|
||||||
logo_object_key,
|
logo_object_key,
|
||||||
|
description,
|
||||||
|
website_url,
|
||||||
|
email,
|
||||||
|
headquarter_address,
|
||||||
created_at,
|
created_at,
|
||||||
updated_at
|
updated_at
|
||||||
FROM
|
FROM
|
||||||
@@ -115,6 +123,10 @@ SELECT
|
|||||||
id,
|
id,
|
||||||
name,
|
name,
|
||||||
logo_object_key,
|
logo_object_key,
|
||||||
|
description,
|
||||||
|
website_url,
|
||||||
|
email,
|
||||||
|
headquarter_address,
|
||||||
created_at,
|
created_at,
|
||||||
updated_at
|
updated_at
|
||||||
FROM
|
FROM
|
||||||
@@ -155,9 +167,13 @@ INSERT INTO organizations (
|
|||||||
id,
|
id,
|
||||||
name,
|
name,
|
||||||
logo_object_key,
|
logo_object_key,
|
||||||
|
description,
|
||||||
|
website_url,
|
||||||
|
email,
|
||||||
|
headquarter_address,
|
||||||
created_at,
|
created_at,
|
||||||
updated_at
|
updated_at
|
||||||
) VALUES (@tenant_id, @id, @name, @logo_object_key, @created_at, @updated_at)
|
) VALUES (@tenant_id, @id, @name, @logo_object_key, @description, @website_url, @email, @headquarter_address, @created_at, @updated_at)
|
||||||
`
|
`
|
||||||
|
|
||||||
args := pgx.StrictNamedArgs{
|
args := pgx.StrictNamedArgs{
|
||||||
@@ -165,6 +181,10 @@ INSERT INTO organizations (
|
|||||||
"id": o.ID,
|
"id": o.ID,
|
||||||
"name": o.Name,
|
"name": o.Name,
|
||||||
"logo_object_key": o.LogoObjectKey,
|
"logo_object_key": o.LogoObjectKey,
|
||||||
|
"description": o.Description,
|
||||||
|
"website_url": o.WebsiteURL,
|
||||||
|
"email": o.Email,
|
||||||
|
"headquarter_address": o.HeadquarterAddress,
|
||||||
"created_at": o.CreatedAt,
|
"created_at": o.CreatedAt,
|
||||||
"updated_at": o.UpdatedAt,
|
"updated_at": o.UpdatedAt,
|
||||||
}
|
}
|
||||||
@@ -187,6 +207,10 @@ UPDATE organizations
|
|||||||
SET
|
SET
|
||||||
name = @name,
|
name = @name,
|
||||||
logo_object_key = @logo_object_key,
|
logo_object_key = @logo_object_key,
|
||||||
|
description = @description,
|
||||||
|
website_url = @website_url,
|
||||||
|
email = @email,
|
||||||
|
headquarter_address = @headquarter_address,
|
||||||
updated_at = @updated_at
|
updated_at = @updated_at
|
||||||
WHERE
|
WHERE
|
||||||
%s
|
%s
|
||||||
@@ -199,6 +223,10 @@ WHERE
|
|||||||
"id": o.ID,
|
"id": o.ID,
|
||||||
"name": o.Name,
|
"name": o.Name,
|
||||||
"logo_object_key": o.LogoObjectKey,
|
"logo_object_key": o.LogoObjectKey,
|
||||||
|
"description": o.Description,
|
||||||
|
"website_url": o.WebsiteURL,
|
||||||
|
"email": o.Email,
|
||||||
|
"headquarter_address": o.HeadquarterAddress,
|
||||||
"updated_at": o.UpdatedAt,
|
"updated_at": o.UpdatedAt,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
"mime"
|
"mime"
|
||||||
|
"net/mail"
|
||||||
"net/url"
|
"net/url"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"time"
|
"time"
|
||||||
@@ -70,6 +71,10 @@ type (
|
|||||||
ID gid.GID
|
ID gid.GID
|
||||||
Name *string
|
Name *string
|
||||||
File *File
|
File *File
|
||||||
|
Description **string
|
||||||
|
WebsiteURL **string
|
||||||
|
Email **string
|
||||||
|
HeadquarterAddress **string
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -168,6 +173,27 @@ func (s OrganizationService) Update(
|
|||||||
organization.Name = *req.Name
|
organization.Name = *req.Name
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if req.Description != nil {
|
||||||
|
organization.Description = *req.Description
|
||||||
|
}
|
||||||
|
|
||||||
|
if req.WebsiteURL != nil {
|
||||||
|
organization.WebsiteURL = *req.WebsiteURL
|
||||||
|
}
|
||||||
|
|
||||||
|
if req.Email != nil {
|
||||||
|
if *req.Email != nil {
|
||||||
|
if _, err := mail.ParseAddress(**req.Email); err != nil {
|
||||||
|
return fmt.Errorf("invalid email address: %w", err)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
organization.Email = *req.Email
|
||||||
|
}
|
||||||
|
|
||||||
|
if req.HeadquarterAddress != nil {
|
||||||
|
organization.HeadquarterAddress = *req.HeadquarterAddress
|
||||||
|
}
|
||||||
|
|
||||||
if req.File != nil {
|
if req.File != nil {
|
||||||
objectKey, err := uuid.NewV7()
|
objectKey, err := uuid.NewV7()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|||||||
@@ -1420,6 +1420,11 @@ type Organization implements Node {
|
|||||||
name: String!
|
name: String!
|
||||||
logoUrl: String @goField(forceResolver: true)
|
logoUrl: String @goField(forceResolver: true)
|
||||||
|
|
||||||
|
description: String
|
||||||
|
websiteUrl: String
|
||||||
|
email: String
|
||||||
|
headquarterAddress: String
|
||||||
|
|
||||||
users(
|
users(
|
||||||
first: Int
|
first: Int
|
||||||
after: CursorKey
|
after: CursorKey
|
||||||
@@ -2765,6 +2770,10 @@ input UpdateOrganizationInput {
|
|||||||
organizationId: ID!
|
organizationId: ID!
|
||||||
name: String
|
name: String
|
||||||
logo: Upload
|
logo: Upload
|
||||||
|
description: String
|
||||||
|
websiteUrl: String
|
||||||
|
email: String
|
||||||
|
headquarterAddress: String
|
||||||
}
|
}
|
||||||
|
|
||||||
input DeleteOrganizationInput {
|
input DeleteOrganizationInput {
|
||||||
|
|||||||
@@ -902,8 +902,11 @@ type ComplexityRoot struct {
|
|||||||
Controls func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.ControlOrderBy, filter *types.ControlFilter) int
|
Controls func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.ControlOrderBy, filter *types.ControlFilter) int
|
||||||
CreatedAt func(childComplexity int) int
|
CreatedAt func(childComplexity int) int
|
||||||
Data func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.DatumOrderBy, filter *types.DatumFilter) int
|
Data func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.DatumOrderBy, filter *types.DatumFilter) int
|
||||||
|
Description func(childComplexity int) int
|
||||||
Documents func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.DocumentOrderBy, filter *types.DocumentFilter) int
|
Documents func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.DocumentOrderBy, filter *types.DocumentFilter) int
|
||||||
|
Email func(childComplexity int) int
|
||||||
Frameworks func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.FrameworkOrderBy) int
|
Frameworks func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.FrameworkOrderBy) int
|
||||||
|
HeadquarterAddress func(childComplexity int) int
|
||||||
ID func(childComplexity int) int
|
ID func(childComplexity int) int
|
||||||
LogoURL func(childComplexity int) int
|
LogoURL func(childComplexity int) int
|
||||||
Measures func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.MeasureOrderBy, filter *types.MeasureFilter) int
|
Measures func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.MeasureOrderBy, filter *types.MeasureFilter) int
|
||||||
@@ -919,6 +922,7 @@ type ComplexityRoot struct {
|
|||||||
UpdatedAt func(childComplexity int) int
|
UpdatedAt func(childComplexity int) int
|
||||||
Users func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.UserOrderBy) int
|
Users func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.UserOrderBy) int
|
||||||
Vendors func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.VendorOrderBy, filter *types.VendorFilter) int
|
Vendors func(childComplexity int, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.VendorOrderBy, filter *types.VendorFilter) int
|
||||||
|
WebsiteURL func(childComplexity int) int
|
||||||
}
|
}
|
||||||
|
|
||||||
OrganizationConnection struct {
|
OrganizationConnection struct {
|
||||||
@@ -1698,6 +1702,7 @@ type ObligationConnectionResolver interface {
|
|||||||
}
|
}
|
||||||
type OrganizationResolver interface {
|
type OrganizationResolver interface {
|
||||||
LogoURL(ctx context.Context, obj *types.Organization) (*string, error)
|
LogoURL(ctx context.Context, obj *types.Organization) (*string, error)
|
||||||
|
|
||||||
Users(ctx context.Context, obj *types.Organization, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.UserOrderBy) (*types.UserConnection, error)
|
Users(ctx context.Context, obj *types.Organization, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.UserOrderBy) (*types.UserConnection, error)
|
||||||
Connectors(ctx context.Context, obj *types.Organization, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.ConnectorOrder) (*types.ConnectorConnection, error)
|
Connectors(ctx context.Context, obj *types.Organization, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.ConnectorOrder) (*types.ConnectorConnection, error)
|
||||||
Frameworks(ctx context.Context, obj *types.Organization, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.FrameworkOrderBy) (*types.FrameworkConnection, error)
|
Frameworks(ctx context.Context, obj *types.Organization, first *int, after *page.CursorKey, last *int, before *page.CursorKey, orderBy *types.FrameworkOrderBy) (*types.FrameworkConnection, error)
|
||||||
@@ -5583,6 +5588,13 @@ func (e *executableSchema) Complexity(ctx context.Context, typeName, field strin
|
|||||||
|
|
||||||
return e.complexity.Organization.Data(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.DatumOrderBy), args["filter"].(*types.DatumFilter)), true
|
return e.complexity.Organization.Data(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.DatumOrderBy), args["filter"].(*types.DatumFilter)), true
|
||||||
|
|
||||||
|
case "Organization.description":
|
||||||
|
if e.complexity.Organization.Description == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.Description(childComplexity), true
|
||||||
|
|
||||||
case "Organization.documents":
|
case "Organization.documents":
|
||||||
if e.complexity.Organization.Documents == nil {
|
if e.complexity.Organization.Documents == nil {
|
||||||
break
|
break
|
||||||
@@ -5595,6 +5607,13 @@ func (e *executableSchema) Complexity(ctx context.Context, typeName, field strin
|
|||||||
|
|
||||||
return e.complexity.Organization.Documents(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.DocumentOrderBy), args["filter"].(*types.DocumentFilter)), true
|
return e.complexity.Organization.Documents(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.DocumentOrderBy), args["filter"].(*types.DocumentFilter)), true
|
||||||
|
|
||||||
|
case "Organization.email":
|
||||||
|
if e.complexity.Organization.Email == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.Email(childComplexity), true
|
||||||
|
|
||||||
case "Organization.frameworks":
|
case "Organization.frameworks":
|
||||||
if e.complexity.Organization.Frameworks == nil {
|
if e.complexity.Organization.Frameworks == nil {
|
||||||
break
|
break
|
||||||
@@ -5607,6 +5626,13 @@ func (e *executableSchema) Complexity(ctx context.Context, typeName, field strin
|
|||||||
|
|
||||||
return e.complexity.Organization.Frameworks(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.FrameworkOrderBy)), true
|
return e.complexity.Organization.Frameworks(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.FrameworkOrderBy)), true
|
||||||
|
|
||||||
|
case "Organization.headquarterAddress":
|
||||||
|
if e.complexity.Organization.HeadquarterAddress == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.HeadquarterAddress(childComplexity), true
|
||||||
|
|
||||||
case "Organization.id":
|
case "Organization.id":
|
||||||
if e.complexity.Organization.ID == nil {
|
if e.complexity.Organization.ID == nil {
|
||||||
break
|
break
|
||||||
@@ -5762,6 +5788,13 @@ func (e *executableSchema) Complexity(ctx context.Context, typeName, field strin
|
|||||||
|
|
||||||
return e.complexity.Organization.Vendors(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.VendorOrderBy), args["filter"].(*types.VendorFilter)), true
|
return e.complexity.Organization.Vendors(childComplexity, args["first"].(*int), args["after"].(*page.CursorKey), args["last"].(*int), args["before"].(*page.CursorKey), args["orderBy"].(*types.VendorOrderBy), args["filter"].(*types.VendorFilter)), true
|
||||||
|
|
||||||
|
case "Organization.websiteUrl":
|
||||||
|
if e.complexity.Organization.WebsiteURL == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.WebsiteURL(childComplexity), true
|
||||||
|
|
||||||
case "OrganizationConnection.edges":
|
case "OrganizationConnection.edges":
|
||||||
if e.complexity.OrganizationConnection.Edges == nil {
|
if e.complexity.OrganizationConnection.Edges == nil {
|
||||||
break
|
break
|
||||||
@@ -9553,6 +9586,11 @@ type Organization implements Node {
|
|||||||
name: String!
|
name: String!
|
||||||
logoUrl: String @goField(forceResolver: true)
|
logoUrl: String @goField(forceResolver: true)
|
||||||
|
|
||||||
|
description: String
|
||||||
|
websiteUrl: String
|
||||||
|
email: String
|
||||||
|
headquarterAddress: String
|
||||||
|
|
||||||
users(
|
users(
|
||||||
first: Int
|
first: Int
|
||||||
after: CursorKey
|
after: CursorKey
|
||||||
@@ -10898,6 +10936,10 @@ input UpdateOrganizationInput {
|
|||||||
organizationId: ID!
|
organizationId: ID!
|
||||||
name: String
|
name: String
|
||||||
logo: Upload
|
logo: Upload
|
||||||
|
description: String
|
||||||
|
websiteUrl: String
|
||||||
|
email: String
|
||||||
|
headquarterAddress: String
|
||||||
}
|
}
|
||||||
|
|
||||||
input DeleteOrganizationInput {
|
input DeleteOrganizationInput {
|
||||||
@@ -20309,6 +20351,14 @@ func (ec *executionContext) fieldContext_Asset_organization(_ context.Context, f
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -20908,6 +20958,14 @@ func (ec *executionContext) fieldContext_Audit_organization(_ context.Context, f
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -22623,6 +22681,14 @@ func (ec *executionContext) fieldContext_ContinualImprovement_organization(_ con
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -26417,6 +26483,14 @@ func (ec *executionContext) fieldContext_Datum_organization(_ context.Context, f
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -28946,6 +29020,14 @@ func (ec *executionContext) fieldContext_Document_organization(_ context.Context
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -32161,6 +32243,14 @@ func (ec *executionContext) fieldContext_Framework_organization(_ context.Contex
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -40542,6 +40632,14 @@ func (ec *executionContext) fieldContext_Nonconformity_organization(_ context.Co
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -41593,6 +41691,14 @@ func (ec *executionContext) fieldContext_Obligation_organization(_ context.Conte
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -42570,6 +42676,170 @@ func (ec *executionContext) fieldContext_Organization_logoUrl(_ context.Context,
|
|||||||
return fc, nil
|
return fc, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_description(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.Description, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_websiteUrl(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.WebsiteURL, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_websiteUrl(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_email(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.Email, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_email(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_headquarterAddress(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.HeadquarterAddress, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_headquarterAddress(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
func (ec *executionContext) _Organization_users(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
func (ec *executionContext) _Organization_users(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
fc, err := ec.fieldContext_Organization_users(ctx, field)
|
fc, err := ec.fieldContext_Organization_users(ctx, field)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -44042,6 +44312,14 @@ func (ec *executionContext) fieldContext_OrganizationEdge_node(_ context.Context
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -45121,6 +45399,14 @@ func (ec *executionContext) fieldContext_ProcessingActivity_organization(_ conte
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -47721,6 +48007,14 @@ func (ec *executionContext) fieldContext_Risk_organization(_ context.Context, fi
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -48546,6 +48840,14 @@ func (ec *executionContext) fieldContext_Snapshot_organization(_ context.Context
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -49449,6 +49751,14 @@ func (ec *executionContext) fieldContext_Task_organization(_ context.Context, fi
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -50323,6 +50633,14 @@ func (ec *executionContext) fieldContext_TrustCenter_organization(_ context.Cont
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -52050,6 +52368,14 @@ func (ec *executionContext) fieldContext_UpdateOrganizationPayload_organization(
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -54062,6 +54388,14 @@ func (ec *executionContext) fieldContext_Vendor_organization(_ context.Context,
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
case "users":
|
case "users":
|
||||||
return ec.fieldContext_Organization_users(ctx, field)
|
return ec.fieldContext_Organization_users(ctx, field)
|
||||||
case "connectors":
|
case "connectors":
|
||||||
@@ -66432,7 +66766,7 @@ func (ec *executionContext) unmarshalInputUpdateOrganizationInput(ctx context.Co
|
|||||||
asMap[k] = v
|
asMap[k] = v
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldsInOrder := [...]string{"organizationId", "name", "logo"}
|
fieldsInOrder := [...]string{"organizationId", "name", "logo", "description", "websiteUrl", "email", "headquarterAddress"}
|
||||||
for _, k := range fieldsInOrder {
|
for _, k := range fieldsInOrder {
|
||||||
v, ok := asMap[k]
|
v, ok := asMap[k]
|
||||||
if !ok {
|
if !ok {
|
||||||
@@ -66460,6 +66794,34 @@ func (ec *executionContext) unmarshalInputUpdateOrganizationInput(ctx context.Co
|
|||||||
return it, err
|
return it, err
|
||||||
}
|
}
|
||||||
it.Logo = data
|
it.Logo = data
|
||||||
|
case "description":
|
||||||
|
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description"))
|
||||||
|
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
|
||||||
|
if err != nil {
|
||||||
|
return it, err
|
||||||
|
}
|
||||||
|
it.Description = data
|
||||||
|
case "websiteUrl":
|
||||||
|
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("websiteUrl"))
|
||||||
|
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
|
||||||
|
if err != nil {
|
||||||
|
return it, err
|
||||||
|
}
|
||||||
|
it.WebsiteURL = data
|
||||||
|
case "email":
|
||||||
|
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
|
||||||
|
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
|
||||||
|
if err != nil {
|
||||||
|
return it, err
|
||||||
|
}
|
||||||
|
it.Email = data
|
||||||
|
case "headquarterAddress":
|
||||||
|
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("headquarterAddress"))
|
||||||
|
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
|
||||||
|
if err != nil {
|
||||||
|
return it, err
|
||||||
|
}
|
||||||
|
it.HeadquarterAddress = data
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -76214,6 +76576,14 @@ func (ec *executionContext) _Organization(ctx context.Context, sel ast.Selection
|
|||||||
}
|
}
|
||||||
|
|
||||||
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
|
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
|
||||||
|
case "description":
|
||||||
|
out.Values[i] = ec._Organization_description(ctx, field, obj)
|
||||||
|
case "websiteUrl":
|
||||||
|
out.Values[i] = ec._Organization_websiteUrl(ctx, field, obj)
|
||||||
|
case "email":
|
||||||
|
out.Values[i] = ec._Organization_email(ctx, field, obj)
|
||||||
|
case "headquarterAddress":
|
||||||
|
out.Values[i] = ec._Organization_headquarterAddress(ctx, field, obj)
|
||||||
case "users":
|
case "users":
|
||||||
field := field
|
field := field
|
||||||
|
|
||||||
|
|||||||
@@ -47,6 +47,10 @@ func NewOrganization(o *coredata.Organization) *Organization {
|
|||||||
return &Organization{
|
return &Organization{
|
||||||
ID: o.ID,
|
ID: o.ID,
|
||||||
Name: o.Name,
|
Name: o.Name,
|
||||||
|
Description: o.Description,
|
||||||
|
WebsiteURL: o.WebsiteURL,
|
||||||
|
Email: o.Email,
|
||||||
|
HeadquarterAddress: o.HeadquarterAddress,
|
||||||
CreatedAt: o.CreatedAt,
|
CreatedAt: o.CreatedAt,
|
||||||
UpdatedAt: o.UpdatedAt,
|
UpdatedAt: o.UpdatedAt,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1198,6 +1198,10 @@ type Organization struct {
|
|||||||
ID gid.GID `json:"id"`
|
ID gid.GID `json:"id"`
|
||||||
Name string `json:"name"`
|
Name string `json:"name"`
|
||||||
LogoURL *string `json:"logoUrl,omitempty"`
|
LogoURL *string `json:"logoUrl,omitempty"`
|
||||||
|
Description *string `json:"description,omitempty"`
|
||||||
|
WebsiteURL *string `json:"websiteUrl,omitempty"`
|
||||||
|
Email *string `json:"email,omitempty"`
|
||||||
|
HeadquarterAddress *string `json:"headquarterAddress,omitempty"`
|
||||||
Users *UserConnection `json:"users"`
|
Users *UserConnection `json:"users"`
|
||||||
Connectors *ConnectorConnection `json:"connectors"`
|
Connectors *ConnectorConnection `json:"connectors"`
|
||||||
Frameworks *FrameworkConnection `json:"frameworks"`
|
Frameworks *FrameworkConnection `json:"frameworks"`
|
||||||
@@ -1666,6 +1670,10 @@ type UpdateOrganizationInput struct {
|
|||||||
OrganizationID gid.GID `json:"organizationId"`
|
OrganizationID gid.GID `json:"organizationId"`
|
||||||
Name *string `json:"name,omitempty"`
|
Name *string `json:"name,omitempty"`
|
||||||
Logo *graphql.Upload `json:"logo,omitempty"`
|
Logo *graphql.Upload `json:"logo,omitempty"`
|
||||||
|
Description *string `json:"description,omitempty"`
|
||||||
|
WebsiteURL *string `json:"websiteUrl,omitempty"`
|
||||||
|
Email *string `json:"email,omitempty"`
|
||||||
|
HeadquarterAddress *string `json:"headquarterAddress,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type UpdateOrganizationPayload struct {
|
type UpdateOrganizationPayload struct {
|
||||||
|
|||||||
@@ -1106,6 +1106,10 @@ func (r *mutationResolver) UpdateOrganization(ctx context.Context, input types.U
|
|||||||
req := probo.UpdateOrganizationRequest{
|
req := probo.UpdateOrganizationRequest{
|
||||||
ID: input.OrganizationID,
|
ID: input.OrganizationID,
|
||||||
Name: input.Name,
|
Name: input.Name,
|
||||||
|
Description: &input.Description,
|
||||||
|
WebsiteURL: &input.WebsiteURL,
|
||||||
|
Email: &input.Email,
|
||||||
|
HeadquarterAddress: &input.HeadquarterAddress,
|
||||||
}
|
}
|
||||||
|
|
||||||
if input.Logo != nil {
|
if input.Logo != nil {
|
||||||
|
|||||||
@@ -37,6 +37,11 @@ type Organization implements Node {
|
|||||||
id: ID!
|
id: ID!
|
||||||
name: String!
|
name: String!
|
||||||
logoUrl: String @goField(forceResolver: true)
|
logoUrl: String @goField(forceResolver: true)
|
||||||
|
|
||||||
|
description: String
|
||||||
|
websiteUrl: String
|
||||||
|
email: String
|
||||||
|
headquarterAddress: String
|
||||||
}
|
}
|
||||||
|
|
||||||
enum DocumentType
|
enum DocumentType
|
||||||
|
|||||||
@@ -117,9 +117,13 @@ type ComplexityRoot struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Organization struct {
|
Organization struct {
|
||||||
|
Description func(childComplexity int) int
|
||||||
|
Email func(childComplexity int) int
|
||||||
|
HeadquarterAddress func(childComplexity int) int
|
||||||
ID func(childComplexity int) int
|
ID func(childComplexity int) int
|
||||||
LogoURL func(childComplexity int) int
|
LogoURL func(childComplexity int) int
|
||||||
Name func(childComplexity int) int
|
Name func(childComplexity int) int
|
||||||
|
WebsiteURL func(childComplexity int) int
|
||||||
}
|
}
|
||||||
|
|
||||||
PageInfo struct {
|
PageInfo struct {
|
||||||
@@ -413,6 +417,27 @@ func (e *executableSchema) Complexity(ctx context.Context, typeName, field strin
|
|||||||
|
|
||||||
return e.complexity.Mutation.ExportReportPDF(childComplexity, args["input"].(types.ExportReportPDFInput)), true
|
return e.complexity.Mutation.ExportReportPDF(childComplexity, args["input"].(types.ExportReportPDFInput)), true
|
||||||
|
|
||||||
|
case "Organization.description":
|
||||||
|
if e.complexity.Organization.Description == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.Description(childComplexity), true
|
||||||
|
|
||||||
|
case "Organization.email":
|
||||||
|
if e.complexity.Organization.Email == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.Email(childComplexity), true
|
||||||
|
|
||||||
|
case "Organization.headquarterAddress":
|
||||||
|
if e.complexity.Organization.HeadquarterAddress == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.HeadquarterAddress(childComplexity), true
|
||||||
|
|
||||||
case "Organization.id":
|
case "Organization.id":
|
||||||
if e.complexity.Organization.ID == nil {
|
if e.complexity.Organization.ID == nil {
|
||||||
break
|
break
|
||||||
@@ -434,6 +459,13 @@ func (e *executableSchema) Complexity(ctx context.Context, typeName, field strin
|
|||||||
|
|
||||||
return e.complexity.Organization.Name(childComplexity), true
|
return e.complexity.Organization.Name(childComplexity), true
|
||||||
|
|
||||||
|
case "Organization.websiteUrl":
|
||||||
|
if e.complexity.Organization.WebsiteURL == nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
|
return e.complexity.Organization.WebsiteURL(childComplexity), true
|
||||||
|
|
||||||
case "PageInfo.endCursor":
|
case "PageInfo.endCursor":
|
||||||
if e.complexity.PageInfo.EndCursor == nil {
|
if e.complexity.PageInfo.EndCursor == nil {
|
||||||
break
|
break
|
||||||
@@ -833,6 +865,11 @@ type Organization implements Node {
|
|||||||
id: ID!
|
id: ID!
|
||||||
name: String!
|
name: String!
|
||||||
logoUrl: String @goField(forceResolver: true)
|
logoUrl: String @goField(forceResolver: true)
|
||||||
|
|
||||||
|
description: String
|
||||||
|
websiteUrl: String
|
||||||
|
email: String
|
||||||
|
headquarterAddress: String
|
||||||
}
|
}
|
||||||
|
|
||||||
enum DocumentType
|
enum DocumentType
|
||||||
@@ -3265,6 +3302,170 @@ func (ec *executionContext) fieldContext_Organization_logoUrl(_ context.Context,
|
|||||||
return fc, nil
|
return fc, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_description(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.Description, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_websiteUrl(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.WebsiteURL, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_websiteUrl(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_email(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.Email, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_email(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) _Organization_headquarterAddress(ctx context.Context, field graphql.CollectedField, obj *types.Organization) (ret graphql.Marshaler) {
|
||||||
|
fc, err := ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
|
if err != nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
ctx = graphql.WithFieldContext(ctx, fc)
|
||||||
|
defer func() {
|
||||||
|
if r := recover(); r != nil {
|
||||||
|
ec.Error(ctx, ec.Recover(ctx, r))
|
||||||
|
ret = graphql.Null
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (any, error) {
|
||||||
|
ctx = rctx // use context from middleware stack in children
|
||||||
|
return obj.HeadquarterAddress, nil
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
ec.Error(ctx, err)
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
if resTmp == nil {
|
||||||
|
return graphql.Null
|
||||||
|
}
|
||||||
|
res := resTmp.(*string)
|
||||||
|
fc.Result = res
|
||||||
|
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (ec *executionContext) fieldContext_Organization_headquarterAddress(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
|
||||||
|
fc = &graphql.FieldContext{
|
||||||
|
Object: "Organization",
|
||||||
|
Field: field,
|
||||||
|
IsMethod: false,
|
||||||
|
IsResolver: false,
|
||||||
|
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
|
||||||
|
return nil, errors.New("field of type String does not have child fields")
|
||||||
|
},
|
||||||
|
}
|
||||||
|
return fc, nil
|
||||||
|
}
|
||||||
|
|
||||||
func (ec *executionContext) _PageInfo_hasNextPage(ctx context.Context, field graphql.CollectedField, obj *types.PageInfo) (ret graphql.Marshaler) {
|
func (ec *executionContext) _PageInfo_hasNextPage(ctx context.Context, field graphql.CollectedField, obj *types.PageInfo) (ret graphql.Marshaler) {
|
||||||
fc, err := ec.fieldContext_PageInfo_hasNextPage(ctx, field)
|
fc, err := ec.fieldContext_PageInfo_hasNextPage(ctx, field)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -4016,6 +4217,14 @@ func (ec *executionContext) fieldContext_TrustCenter_organization(_ context.Cont
|
|||||||
return ec.fieldContext_Organization_name(ctx, field)
|
return ec.fieldContext_Organization_name(ctx, field)
|
||||||
case "logoUrl":
|
case "logoUrl":
|
||||||
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
return ec.fieldContext_Organization_logoUrl(ctx, field)
|
||||||
|
case "description":
|
||||||
|
return ec.fieldContext_Organization_description(ctx, field)
|
||||||
|
case "websiteUrl":
|
||||||
|
return ec.fieldContext_Organization_websiteUrl(ctx, field)
|
||||||
|
case "email":
|
||||||
|
return ec.fieldContext_Organization_email(ctx, field)
|
||||||
|
case "headquarterAddress":
|
||||||
|
return ec.fieldContext_Organization_headquarterAddress(ctx, field)
|
||||||
}
|
}
|
||||||
return nil, fmt.Errorf("no field named %q was found under type Organization", field.Name)
|
return nil, fmt.Errorf("no field named %q was found under type Organization", field.Name)
|
||||||
},
|
},
|
||||||
@@ -7781,6 +7990,14 @@ func (ec *executionContext) _Organization(ctx context.Context, sel ast.Selection
|
|||||||
}
|
}
|
||||||
|
|
||||||
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
|
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
|
||||||
|
case "description":
|
||||||
|
out.Values[i] = ec._Organization_description(ctx, field, obj)
|
||||||
|
case "websiteUrl":
|
||||||
|
out.Values[i] = ec._Organization_websiteUrl(ctx, field, obj)
|
||||||
|
case "email":
|
||||||
|
out.Values[i] = ec._Organization_email(ctx, field, obj)
|
||||||
|
case "headquarterAddress":
|
||||||
|
out.Values[i] = ec._Organization_headquarterAddress(ctx, field, obj)
|
||||||
default:
|
default:
|
||||||
panic("unknown field " + strconv.Quote(field.Name))
|
panic("unknown field " + strconv.Quote(field.Name))
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,5 +22,9 @@ func NewOrganization(o *coredata.Organization) *Organization {
|
|||||||
return &Organization{
|
return &Organization{
|
||||||
ID: o.ID,
|
ID: o.ID,
|
||||||
Name: o.Name,
|
Name: o.Name,
|
||||||
|
Description: o.Description,
|
||||||
|
WebsiteURL: o.WebsiteURL,
|
||||||
|
Email: o.Email,
|
||||||
|
HeadquarterAddress: o.HeadquarterAddress,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -106,6 +106,10 @@ type Organization struct {
|
|||||||
ID gid.GID `json:"id"`
|
ID gid.GID `json:"id"`
|
||||||
Name string `json:"name"`
|
Name string `json:"name"`
|
||||||
LogoURL *string `json:"logoUrl,omitempty"`
|
LogoURL *string `json:"logoUrl,omitempty"`
|
||||||
|
Description *string `json:"description,omitempty"`
|
||||||
|
WebsiteURL *string `json:"websiteUrl,omitempty"`
|
||||||
|
Email *string `json:"email,omitempty"`
|
||||||
|
HeadquarterAddress *string `json:"headquarterAddress,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (Organization) IsNode() {}
|
func (Organization) IsNode() {}
|
||||||
|
|||||||
Reference in New Issue
Block a user