if have't any bucket user can't create contacts
This commit is contained in:
parent
662d464271
commit
379d9ecb8b
@ -229,19 +229,21 @@ const handleDeleteContact = async (overrideId = null) => {
|
|||||||
color:"primary",
|
color:"primary",
|
||||||
onClick: () => setOpenBucketModal(true),
|
onClick: () => setOpenBucketModal(true),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
actions.push({
|
if ( buckets?.length > 0 )
|
||||||
label: "New Contact",
|
{
|
||||||
icon: "bx bx-plus-circle",
|
actions.push( {
|
||||||
color: "warning",
|
label: "New Contact",
|
||||||
onClick: () => setIsOpenModal(true),
|
icon: "bx bx-plus-circle",
|
||||||
} );
|
color: "warning",
|
||||||
|
onClick: () => setIsOpenModal( true ),
|
||||||
|
} );
|
||||||
|
}
|
||||||
|
|
||||||
setActions(actions);
|
setActions(actions);
|
||||||
|
|
||||||
return () => setActions([]);
|
return () => setActions([]);
|
||||||
}, [IsPage]);
|
}, [IsPage,buckets]);
|
||||||
useEffect( () =>
|
useEffect( () =>
|
||||||
{
|
{
|
||||||
setPerfence(prefernceContacts)
|
setPerfence(prefernceContacts)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user