Remove deprecated SOA code

Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
Sacha Al Himdani
2026-02-17 13:55:56 +01:00
parent e9263fb42f
commit 40e4db9278
50 changed files with 285 additions and 2669 deletions

View File

@@ -44,30 +44,6 @@ export const description: INodeProperties[] = [
description: 'The name of the control',
required: true,
},
{
displayName: 'Status',
name: 'status',
type: 'options',
displayOptions: {
show: {
resource: ['control'],
operation: ['create'],
},
},
options: [
{
name: 'Included',
value: 'INCLUDED',
},
{
name: 'Excluded',
value: 'EXCLUDED',
},
],
default: 'INCLUDED',
description: 'The status of the control',
required: true,
},
{
displayName: 'Description',
name: 'description',
@@ -81,19 +57,6 @@ export const description: INodeProperties[] = [
default: '',
description: 'The description of the control',
},
{
displayName: 'Exclusion Justification',
name: 'exclusionJustification',
type: 'string',
displayOptions: {
show: {
resource: ['control'],
operation: ['create'],
},
},
default: '',
description: 'The justification for excluding the control',
},
];
export async function execute(
@@ -103,9 +66,7 @@ export async function execute(
const frameworkId = this.getNodeParameter('frameworkId', itemIndex) as string;
const sectionTitle = this.getNodeParameter('sectionTitle', itemIndex) as string;
const name = this.getNodeParameter('name', itemIndex) as string;
const status = this.getNodeParameter('status', itemIndex) as string;
const description = this.getNodeParameter('description', itemIndex, '') as string;
const exclusionJustification = this.getNodeParameter('exclusionJustification', itemIndex, '') as string;
const query = `
mutation CreateControl($input: CreateControlInput!) {
@@ -116,8 +77,6 @@ export async function execute(
sectionTitle
name
description
status
exclusionJustification
createdAt
updatedAt
}
@@ -131,9 +90,8 @@ export async function execute(
frameworkId,
sectionTitle,
name,
status,
bestPractice: true,
...(description && { description }),
...(exclusionJustification && { exclusionJustification }),
},
};
@@ -144,4 +102,3 @@ export async function execute(
pairedItem: { item: itemIndex },
};
}

View File

@@ -32,8 +32,6 @@ export async function execute(
sectionTitle
name
description
status
exclusionJustification
createdAt
updatedAt
}

View File

@@ -67,8 +67,6 @@ export async function execute(
sectionTitle
name
description
status
exclusionJustification
createdAt
updatedAt
}

View File

@@ -55,42 +55,6 @@ export const description: INodeProperties[] = [
default: '',
description: 'The description of the control',
},
{
displayName: 'Status',
name: 'status',
type: 'options',
displayOptions: {
show: {
resource: ['control'],
operation: ['update'],
},
},
options: [
{
name: 'Included',
value: 'INCLUDED',
},
{
name: 'Excluded',
value: 'EXCLUDED',
},
],
default: 'INCLUDED',
description: 'The status of the control',
},
{
displayName: 'Exclusion Justification',
name: 'exclusionJustification',
type: 'string',
displayOptions: {
show: {
resource: ['control'],
operation: ['update'],
},
},
default: '',
description: 'The justification for excluding the control',
},
];
export async function execute(
@@ -101,8 +65,6 @@ export async function execute(
const sectionTitle = this.getNodeParameter('sectionTitle', itemIndex, '') as string;
const name = this.getNodeParameter('name', itemIndex, '') as string;
const description = this.getNodeParameter('description', itemIndex, '') as string;
const status = this.getNodeParameter('status', itemIndex, '') as string;
const exclusionJustification = this.getNodeParameter('exclusionJustification', itemIndex, '') as string;
const query = `
mutation UpdateControl($input: UpdateControlInput!) {
@@ -112,8 +74,6 @@ export async function execute(
sectionTitle
name
description
status
exclusionJustification
createdAt
updatedAt
}
@@ -125,8 +85,6 @@ export async function execute(
if (sectionTitle) input.sectionTitle = sectionTitle;
if (name) input.name = name;
if (description) input.description = description;
if (status) input.status = status;
if (exclusionJustification) input.exclusionJustification = exclusionJustification;
const responseData = await proboApiRequest.call(this, query, { input });
@@ -135,4 +93,3 @@ export async function execute(
pairedItem: { item: itemIndex },
};
}

View File

@@ -6,7 +6,6 @@ type Props = {
active?: boolean;
id: string;
description?: string;
excluded?: boolean;
to: string;
} & HTMLAttributes<HTMLAnchorElement>;
@@ -27,39 +26,19 @@ const classNames = tv({
id: "bg-highlight",
},
},
excluded: {
true: {
wrapper: "opacity-60",
},
false: {
wrapper: "",
},
},
},
compoundVariants: [
{
active: true,
excluded: true,
class: {
wrapper: "bg-tertiary-pressed opacity-60",
id: "bg-active",
},
},
],
defaultVariants: {
active: false,
excluded: false,
},
});
export function ControlItem({ active, id, description, excluded, to, ...props }: Props) {
export function ControlItem({ active, id, description, to, ...props }: Props) {
const {
wrapper,
id: idCls,
description: descriptionCls,
} = classNames({
active,
excluded,
});
const ref = useRef<HTMLAnchorElement>(null);