Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.
TypeScript ai-agentsbill-of-materialserpinventory-managementleanmanufacturingmanufacturing-execution-systemmcp-servermesmrpopen-source-erppostgresqlproduction-planningqmsquality-management-systemreact-routerself-hostedsupabasetraceabilitytypescript
fixed this
alidauda93d8cbaed6bd
diff --git a/apps/carbon/app/components/Form/Color.tsx b/apps/carbon/app/components/Form/Color.tsxindex e7d36d10fd..b1c8140a4d 100644--- a/apps/carbon/app/components/Form/Color.tsx+++ b/apps/carbon/app/components/Form/Color.tsx@@ -35,10 +35,8 @@ const ColorPicker = ({ name, label }: ColorFieldProps) => {<buttonclassName="inline-flex items-center justify-center whitespace-nowrap rounded-md font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 h-8 w-8 border border-border"style={{ background: value }}- onClick={(event) => {- event.preventDefault(); // Prevent default action- disclosure.onToggle();- }}+ onClick={disclosure.onToggle}+ type="button"/><HexColorInputcolor={value}diff --git a/packages/database/supabase/migrations/20240223235518_add_search_functionality_to_equipment_and_work_cell_types.sql b/packages/database/supabase/migrations/20240223235518_add_search_functionality_to_equipment_and_work_cell_types.sqlindex c33979f761..7a402ca641 100644--- a/packages/database/supabase/migrations/20240223235518_add_search_functionality_to_equipment_and_work_cell_types.sql+++ b/packages/database/supabase/migrations/20240223235518_add_search_functionality_to_equipment_and_work_cell_types.sql@@ -5,7 +5,7 @@ CREATE FUNCTION public.create_work_cell_type_search_result()RETURNS TRIGGER AS $$BEGININSERT INTO public.search(name, description, entity, uuid, link)- VALUES (new.id, new.id || ' ' || new.name || ' ' || COALESCE(new.description, ''), 'Part', new.id, '/x/resources/work-cells/' || new.id);+ VALUES (new.name, COALESCE(new.description, ''), 'Resource', new.id, '/x/resources/work-cells/' || new.id);RETURN new;END;$$ LANGUAGE plpgsql SECURITY DEFINER;@@ -18,8 +18,8 @@ CREATE FUNCTION public.update_work_cell_type_search_result()RETURNS TRIGGER AS $$BEGINIF (old.name <> new.name OR old.description <> new.description) THEN- UPDATE public.search SET name = new.name, description = new.id || ' ' || new.name || ' ' || COALESCE(new.description, '')- WHERE entity = 'Part' AND uuid = new.id;+ UPDATE public.search SET name = new.name, description = COALESCE(new.description, '')+ WHERE entity = 'Resource' AND uuid = new.id;END IF;RETURN new;END;@@ -32,7 +32,7 @@ CREATE TRIGGER update_work_cell_type_search_resultCREATE FUNCTION public.delete_work_cell_type_search_result()RETURNS TRIGGER AS $$BEGIN- DELETE FROM public.search WHERE entity = 'Part' AND uuid = old.id;+ DELETE FROM public.search WHERE entity = 'Resource' AND uuid = old.id;RETURN old;END;$$ LANGUAGE plpgsql SECURITY DEFINER;@@ -47,7 +47,7 @@ CREATE FUNCTION public.create_equipment_type_search_result()RETURNS TRIGGER AS $$BEGININSERT INTO public.search(name, description, entity, uuid, link)- VALUES (new.id, new.id || ' ' || new.name || ' ' || COALESCE(new.description, ''), 'Part', new.id, '/x/resources/equipment/' || new.id);+ VALUES (new.name,COALESCE(new.description, ''), 'Resource', new.id, '/x/resources/equipment/' || new.id);RETURN new;END;$$ LANGUAGE plpgsql SECURITY DEFINER;@@ -60,8 +60,8 @@ CREATE FUNCTION public.update_equipment_type_search_result()RETURNS TRIGGER AS $$BEGINIF (old.name <> new.name OR old.description <> new.description) THEN- UPDATE public.search SET name = new.name, description = new.id || ' ' || new.name || ' ' || COALESCE(new.description, '')- WHERE entity = 'Part' AND uuid = new.id;+ UPDATE public.search SET name = new.name, description = COALESCE(new.description, '')+ WHERE entity = 'Resource' AND uuid = new.id;END IF;RETURN new;END;@@ -74,7 +74,7 @@ CREATE TRIGGER update_equipment_type_search_resultCREATE FUNCTION public.delete_equipment_type_search_result()RETURNS TRIGGER AS $$BEGIN- DELETE FROM public.search WHERE entity = 'Part' AND uuid = old.id;+ DELETE FROM public.search WHERE entity = 'Resource' AND uuid = old.id;RETURN old;END;$$ LANGUAGE plpgsql SECURITY DEFINER;