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
fix: data type not showing up on edit
Brad Barbin5ff9c47e0c2e
diff --git a/apps/carbon/app/modules/settings/ui/CustomFields/CustomFieldForm.tsx b/apps/carbon/app/modules/settings/ui/CustomFields/CustomFieldForm.tsxindex 681d0c3a23..fe1609645e 100644--- a/apps/carbon/app/modules/settings/ui/CustomFields/CustomFieldForm.tsx+++ b/apps/carbon/app/modules/settings/ui/CustomFields/CustomFieldForm.tsx@@ -62,6 +62,8 @@ const CustomFieldForm = ({);};+ console.log({ initialValues });+return (<Draweropendiff --git a/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.$attributeId.tsx b/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.$attributeId.tsxindex fc29298091..4f22be78d6 100644--- a/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.$attributeId.tsx+++ b/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.$attributeId.tsx@@ -51,7 +51,8 @@ export default function EditAttributeRoute() {initialValues={{id: attribute?.id,name: attribute?.name,- attributeDataTypeId: attribute?.attributeDataTypeId,+ // @ts-ignore+ attributeDataTypeId: attribute?.attributeDataTypeId.toString(),userAttributeCategoryId: attribute?.userAttributeCategoryId,canSelfManage: attribute.canSelfManage ?? true,listOptions: attribute?.listOptions ?? [],diff --git a/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.new.tsx b/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.new.tsxindex d97688aa45..e6ae7910ef 100644--- a/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.new.tsx+++ b/apps/carbon/app/routes/x+/resources+/attributes.list.$categoryId.new.tsx@@ -19,7 +19,8 @@ export default function NewAttributeRoute() {<AttributeForminitialValues={{name: "",- attributeDataTypeId: DataType.Text,+ // @ts-ignore+ attributeDataTypeId: DataType.Text.toString(),userAttributeCategoryId: categoryId,canSelfManage: true,}}diff --git a/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.$id.tsx b/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.$id.tsxindex 6beebdbfaa..e463beadba 100644--- a/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.$id.tsx+++ b/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.$id.tsx@@ -98,7 +98,8 @@ export default function UpdateCustomFieldRoute() {initialValues={{id: customField.id,name: customField.name,- dataTypeId: customField.dataTypeId || DataType.Text,+ // @ts-ignore+ dataTypeId: (customField.dataTypeId || DataType.Text).toString(),customFieldTableId: tableId,}}dataTypes={routeData?.dataTypes ?? []}diff --git a/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.new.tsx b/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.new.tsxindex 9874c811a9..e56e24d32c 100644--- a/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.new.tsx+++ b/apps/carbon/app/routes/x+/settings+/custom-fields.$tableId.new.tsx@@ -66,7 +66,8 @@ export default function NewCustomFieldRoute() {<CustomFieldForminitialValues={{name: "",- dataTypeId: DataType.Text,+ // @ts-ignore+ dataTypeId: DataType.Text.toString(),customFieldTableId: tableId,}}dataTypes={routeData?.dataTypes ?? []}