File tree Expand file tree Collapse file tree
security-admin/src/main/webapp/react-webapp/src/views/ServiceManager Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ import arrayMutators from "final-form-arrays";
2525import { FieldArray } from "react-final-form-arrays" ;
2626import Select from "react-select" ;
2727import AsyncSelect from "react-select/async" ;
28+ import AsyncCreatableSelect from "react-select/async-creatable" ;
2829import { RegexValidation , additionalServiceConfigs } from "Utils/XAEnums" ;
2930import { fetchApi } from "Utils/fetchAPI" ;
3031import ServiceAuditFilter from "./ServiceAuditFilter" ;
@@ -675,7 +676,7 @@ class ServiceForm extends Component {
675676 key = { "configs." + additionalConfig . name + index }
676677 id = { "configs." + additionalConfig . name }
677678 data-cy = { "configs." + additionalConfig . name }
678- component = { this . AsyncSelectField }
679+ component = { this . AsyncCreatableSelectField }
679680 loadOptions = {
680681 additionalConfig . type == "user"
681682 ? this . fetchUsers
@@ -991,6 +992,10 @@ class ServiceForm extends Component {
991992 < AsyncSelect { ...input } { ...rest } cacheOptions />
992993 ) ;
993994
995+ AsyncCreatableSelectField = ( { input, ...rest } ) => (
996+ < AsyncCreatableSelect { ...input } { ...rest } />
997+ ) ;
998+
994999 fetchUsers = async ( inputValue ) => {
9951000 let params = { name : inputValue || "" , isVisible : 1 } ;
9961001 let op = [ ] ;
You can’t perform that action at this time.
0 commit comments