import { Form } from 'react-bootstrap'; import RequiredField from "./RequiredField"; import { validateUUID } from '../../../services/utils'; function Selector(props) { const { complex, disabled, errors, inputName, label, onChange, // controlled onChange (if provided) value, // controlled value (if provided) placeholder, register, validationText, values } = props; if (!values) return 'no values'; // Special case: if this is for companyId, render a hidden input with the default company info. const defaultCompanyId = localStorage.getItem('Uniti.defaultCompanyId'); const defaultCompanyName = localStorage.getItem('Uniti.defaultCompanyName'); if (validateUUID(defaultCompanyId) && defaultCompanyName && inputName === 'companyId') { return (