Markus Michalski FAQ

Product Custom Inputs: Troubleshooting

Troubleshooting Product Custom Inputs: missing menu entry, fields not appearing, locked button, 404 on the Shop API, known limitations and FAQ.

Deutsche Version

Back to overview

Product Custom Inputs: Troubleshooting

This documentation always describes the latest published version.

The admin menu entry is missing

Symptom: There is no "Product Custom Input Fields" entry under "MMKreativ Plugins" (the group itself can come from another plugin).

Check: Is the route import present in config/routes.yaml? The plugin deliberately hides the entry when the route is not registered, instead of throwing an error.

Solution: Add the import @MmdSyliusProductCustomInputsPlugin/config/routes/admin.yaml (see Installation) and clear the cache. The setup command also prints the snippet when the import is missing.

The setup command aborts

Symptom: mmd:product-custom-inputs:setup ends with an error message.

Check:

  1. Does it report that migrations the plugin builds on are still open ("Migrations this plugin builds on are still open")? Then Sylius core migrations have not run yet.
  2. Does it report that the migrations are not registered with Doctrine? Then the bundle is not enabled, or sylius_core.prepend_doctrine_migrations is set to false.

Solution: In the first case, run php bin/console doctrine:migrations:migrate and repeat the setup command. In the second case, check the bundle entry and the setting.

The fields do not appear in the add-to-cart form

Symptom: The input fields are missing on the product page.

Check:

  1. Is the field attached to the product in the admin (product form, "General" tab)?
  2. Is the "Enabled" switch on the settings page turned on?
  3. Has the setup command run?

Solution: Attach the field, enable the switch or run php bin/console mmd:product-custom-inputs:setup.

The plugin does not abort on database errors but logs them: if the table does not exist yet, the form renders without fields, and if the switch cannot be read, the plugin counts as enabled.

So when fields are missing, check the log first.

The button stays locked after a validation error

Symptom: After an invalid input, "Add to cart" cannot be clicked anymore, even after the correction.

Check: Do you override custom_inputs.html.twig on the product page?

Solution: Take over the data-model handling from the original template (see Storefront).

POST to the Shop API returns 404

Symptom: POST .../custom-inputs responds with 404 although the order and item exist.

Check:

  1. Is the order still a cart?
  2. Does the order belong to the signed-in customer, or is it a guest order?
  3. Does the field belong to the item's product?
  4. Is the plugin enabled in the admin?

Solution: Fix whichever case applies. All four deliberately produce the same 404 response.

New inputs overwrite old ones

This is intended: adding the same variant to the cart again increases the quantity of the existing line, and the new inputs replace the previous ones.

Known limitations

FAQ

Can a field behave differently on each product? No. Required flag, position and all limits belong to the field. For different rules, create a second field.

Are there per-channel settings? No, only the shop-wide switch.

Do values survive when I detach a field from a product? Yes, inputs already collected on order items stay. If you delete the field itself, its values are deleted with it.