File tree Expand file tree Collapse file tree 2 files changed +14
-14
lines changed
apps/web/src/features/group Expand file tree Collapse file tree 2 files changed +14
-14
lines changed Original file line number Diff line number Diff line change @@ -14,23 +14,21 @@ export type AvailableInstrumentOptions = {
1414} ;
1515
1616export type ManageGroupFormProps = {
17- availableInstrumentOptions : AvailableInstrumentOptions ;
18- initialValues : {
19- accessibleFormInstrumentIds : Set < string > ;
20- accessibleInteractiveInstrumentIds : Set < string > ;
21- defaultIdentificationMethod ?: SubjectIdentificationMethod ;
22- idValidationRegex ?: null | string ;
17+ data : {
18+ availableInstrumentOptions : AvailableInstrumentOptions ;
19+ initialValues : {
20+ accessibleFormInstrumentIds : Set < string > ;
21+ accessibleInteractiveInstrumentIds : Set < string > ;
22+ defaultIdentificationMethod ?: SubjectIdentificationMethod ;
23+ idValidationRegex ?: null | string ;
24+ } ;
2325 } ;
2426 onSubmit : ( data : Partial < UpdateGroupData > ) => Promisable < any > ;
2527 readOnly : boolean ;
2628} ;
2729
28- export const ManageGroupForm = ( {
29- availableInstrumentOptions,
30- initialValues,
31- onSubmit,
32- readOnly
33- } : ManageGroupFormProps ) => {
30+ export const ManageGroupForm = ( { data, onSubmit, readOnly } : ManageGroupFormProps ) => {
31+ const { availableInstrumentOptions, initialValues } = data ;
3432 const { t } = useTranslation ( ) ;
3533
3634 let description = t ( 'group.manage.accessibleInstrumentsDesc' ) ;
Original file line number Diff line number Diff line change @@ -71,8 +71,10 @@ export const ManageGroupPage = () => {
7171 </ PageHeader >
7272
7373 < ManageGroupForm
74- availableInstrumentOptions = { availableInstrumentOptions }
75- initialValues = { initialValues }
74+ data = { {
75+ availableInstrumentOptions,
76+ initialValues
77+ } }
7678 readOnly = { Boolean ( setupState . data ?. isDemo && import . meta. env . PROD ) }
7779 onSubmit = { async ( data ) => {
7880 const updatedGroup = await updateGroupMutation . mutateAsync ( data ) ;
You can’t perform that action at this time.
0 commit comments