diff --git a/.changeset/mean-wasps-cover.md b/.changeset/mean-wasps-cover.md
new file mode 100644
index 00000000..14ff809e
--- /dev/null
+++ b/.changeset/mean-wasps-cover.md
@@ -0,0 +1,5 @@
+---
+'@smartcontractkit/operator-ui': patch
+---
+
+Add OCR2 plugins selection for FMS
diff --git a/src/components/Form/ChainConfigurationForm.test.tsx b/src/components/Form/ChainConfigurationForm.test.tsx
index 53758455..cdda3f56 100644
--- a/src/components/Form/ChainConfigurationForm.test.tsx
+++ b/src/components/Form/ChainConfigurationForm.test.tsx
@@ -26,6 +26,7 @@ describe('ChainConfigurationForm', () => {
ocr2Multiaddr: '',
ocr2P2PPeerID: '',
ocr2KeyBundleID: '',
+ ocr2MedianPluginEnabled: false,
}
render(
@@ -72,6 +73,7 @@ describe('ChainConfigurationForm', () => {
ocr2Multiaddr: '',
ocr2P2PPeerID: '',
ocr2KeyBundleID: '',
+ ocr2MedianPluginEnabled: false,
}
render(
@@ -126,6 +128,7 @@ describe('ChainConfigurationForm', () => {
ocr2Multiaddr: '',
ocr2P2PPeerID: '',
ocr2KeyBundleID: '',
+ ocr2MedianPluginEnabled: false,
}
render(
diff --git a/src/components/Form/ChainConfigurationForm.tsx b/src/components/Form/ChainConfigurationForm.tsx
index d0528761..b4fb3a90 100644
--- a/src/components/Form/ChainConfigurationForm.tsx
+++ b/src/components/Form/ChainConfigurationForm.tsx
@@ -38,6 +38,7 @@ export type FormValues = {
ocr2Multiaddr?: string | null
ocr2P2PPeerID?: string | null
ocr2KeyBundleID?: string | null
+ ocr2MedianPluginEnabled: boolean
}
const ValidationSchema = Yup.object().shape({
@@ -81,6 +82,7 @@ const ValidationSchema = Yup.object().shape({
then: Yup.string().required('Required').nullable(),
})
.nullable(),
+ ocr2MedianPluginEnabled: Yup.boolean().required('Required'),
})
const styles = (theme: Theme) => {
@@ -429,7 +431,23 @@ export const ChainConfigurationForm = withStyles(styles)(
))}
+
+
+ Supported Plugins
+
+
+
+
+
>
+
)}
>
diff --git a/src/hooks/queries/useFeedsManagersWithProposalsQuery.ts b/src/hooks/queries/useFeedsManagersWithProposalsQuery.ts
index dc8a924c..6d692d57 100644
--- a/src/hooks/queries/useFeedsManagersWithProposalsQuery.ts
+++ b/src/hooks/queries/useFeedsManagersWithProposalsQuery.ts
@@ -23,6 +23,9 @@ const FEEDS_MANAGER__CHAIN_CONFIG_FIELDS = gql`
multiaddr
p2pPeerID
keyBundleID
+ plugins {
+ median
+ }
}
}
`
diff --git a/src/screens/FeedsManager/EditSupportedChainDialog.tsx b/src/screens/FeedsManager/EditSupportedChainDialog.tsx
index be9ed230..82ac74c9 100644
--- a/src/screens/FeedsManager/EditSupportedChainDialog.tsx
+++ b/src/screens/FeedsManager/EditSupportedChainDialog.tsx
@@ -71,6 +71,7 @@ export const EditSupportedChainDialog = ({
ocr2Multiaddr: cfg.ocr2JobConfig.multiaddr,
ocr2P2PPeerID: cfg.ocr2JobConfig.p2pPeerID,
ocr2KeyBundleID: cfg.ocr2JobConfig.keyBundleID,
+ ocr2MedianPluginEnabled: cfg.ocr2JobConfig.plugins.median,
}
const chainIDs: string[] = chainData
diff --git a/src/screens/FeedsManager/NewSupportedChainDialog.tsx b/src/screens/FeedsManager/NewSupportedChainDialog.tsx
index b8a91c08..234b9bc7 100644
--- a/src/screens/FeedsManager/NewSupportedChainDialog.tsx
+++ b/src/screens/FeedsManager/NewSupportedChainDialog.tsx
@@ -61,6 +61,7 @@ export const NewSupportedChainDialog = ({ onClose, open, onSubmit }: Props) => {
ocr2Multiaddr: '',
ocr2P2PPeerID: '',
ocr2KeyBundleID: '',
+ ocr2MedianPluginEnabled: false,
}
const chainIDs: string[] = chainData
diff --git a/src/screens/FeedsManager/SupportedChainsCard.tsx b/src/screens/FeedsManager/SupportedChainsCard.tsx
index 73c49fc1..952a06da 100644
--- a/src/screens/FeedsManager/SupportedChainsCard.tsx
+++ b/src/screens/FeedsManager/SupportedChainsCard.tsx
@@ -221,6 +221,7 @@ export const SupportedChainsCard = withStyles(styles)(
values.ocr2P2PPeerID !== '' ? values.ocr2P2PPeerID : null,
ocr2KeyBundleID:
values.ocr2KeyBundleID != '' ? values.ocr2KeyBundleID : null,
+ ocr2Plugins: `{"median":${values.ocr2MedianPluginEnabled}}`
},
},
})
@@ -292,6 +293,7 @@ export const SupportedChainsCard = withStyles(styles)(
values.ocr2P2PPeerID !== '' ? values.ocr2P2PPeerID : null,
ocr2KeyBundleID:
values.ocr2KeyBundleID != '' ? values.ocr2KeyBundleID : null,
+ ocr2Plugins: `{"median":${values.ocr2MedianPluginEnabled}}`
},
},
})