export const getOrgCrmListByOrgId = async (orgId: Tables<"organisation">["id"]) => {
return await supabase
.from('crm')
.select(`*,crm_config(*),crm_project(*), organisation_crm!inner(*)`)
.eq('organisation_crm.organisation_id', orgId)
.throwOnError()
.then(res => res.data);
}
export const getOrgCrmListByOrgId = async (orgId: Tables<"organisation">["id"]) => {
return await supabase
.from('crm')
.select(`*,crm_config(*),crm_project(*), organisation_crm!inner(*)`)
.eq('organisation_crm.organisation_id', orgId)
.throwOnError()
.then(res => res.data);
}