Feat: On Company Show, I can create a person and add it to the company (#1256)
* On Company Show, I can create a person and add it to the company Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: RubensRafael <rubensrafael2@live.com> * Add minor refactors Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: RubensRafael <rubensrafael2@live.com> --------- Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: RubensRafael <rubensrafael2@live.com>
This commit is contained in:
@ -10,6 +10,7 @@ export type OwnProps = {
|
||||
personId: string | null;
|
||||
onSubmit: (newPersonId: PersonForSelect | null) => void;
|
||||
onCancel?: () => void;
|
||||
onCreate?: () => void;
|
||||
excludePersonIds?: string[];
|
||||
};
|
||||
|
||||
@ -21,6 +22,7 @@ export function PeoplePicker({
|
||||
personId,
|
||||
onSubmit,
|
||||
onCancel,
|
||||
onCreate,
|
||||
excludePersonIds,
|
||||
}: OwnProps) {
|
||||
const [searchFilter] = useRecoilScopedState(
|
||||
@ -53,6 +55,7 @@ export function PeoplePicker({
|
||||
<SingleEntitySelect
|
||||
onEntitySelected={handleEntitySelected}
|
||||
onCancel={onCancel}
|
||||
onCreate={onCreate}
|
||||
entities={{
|
||||
loading: people.loading,
|
||||
entitiesToSelect: people.entitiesToSelect,
|
||||
|
||||
Reference in New Issue
Block a user