I can manage layout on product's "manage form display",
But it doesn't take effect when edit a product.

Comments

caseylau created an issue. See original summary.

lawxen’s picture

If I make this change:

- *       "default" = "Drupal\commerce_product\Form\ProductForm",
- *       "add" = "Drupal\commerce_product\Form\ProductForm",
- *       "edit" = "Drupal\commerce_product\Form\ProductForm",
+ *       "default" = "Drupal\Core\Entity\ContentEntityForm",
+ *       "add" = "Drupal\Core\Entity\ContentEntityForm",
+ *       "edit" = "Drupal\Core\Entity\ContentEntityForm",

Then the layout builder will take effect on product's "edit form" .
So the problem caused by Drupal\commerce_product\Form\ProductForm .

lawxen’s picture

Status: Active » Needs work
StatusFileSize
new589 bytes

"Deleting this line" make the layout take effect on commerce_product's "edit_form"

skyredwang’s picture

We need to find the documentation in layout builder why that line matters

lawxen’s picture

Title: layout builder dosn't take effect on product's form level » drupal core's field_layout dosn't take effect on product's "form display"
tim.plunkett’s picture

Title: drupal core's field_layout dosn't take effect on product's "form display" » Field Layout breaks when '#tree' => TRUE is used in an entity form
Project: Commerce Core » Drupal core
Version: 8.x-2.x-dev » 8.7.x-dev
Component: Commerce » field_layout.module
Status: Needs work » Needs review
StatusFileSize
new628 bytes

I believe this might fix it.

Status: Needs review » Needs work

The last submitted patch, 6: 2997366-fl-tree-6.patch, failed testing. View results

lawxen’s picture

Status: Needs work » Needs review
StatusFileSize
new1.18 KB
new421 bytes

Fix the failing test

lawxen’s picture

@tim.plunkett Really thanks for fix this issue
https://www.drupal.org/project/commerce/issues/2998975 .
This is a relevant issue which make field_layout doesn't work either, where do you think this issue should be fixed, Drupal core or commerce itself?

Version: 8.7.x-dev » 8.8.x-dev

Drupal 8.7.0-alpha1 will be released the week of March 11, 2019, which means new developments and disruptive changes should now be targeted against the 8.8.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.0-alpha1 will be released the week of October 14th, 2019, which means new developments and disruptive changes should now be targeted against the 8.9.x-dev branch. (Any changes to 8.9.x will also be committed to 9.0.x in preparation for Drupal 9’s release, but some changes like significant feature additions will be deferred to 9.1.x.). For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.9.x-dev » 9.1.x-dev

Drupal 8.9.0-beta1 was released on March 20, 2020. 8.9.x is the final, long-term support (LTS) minor release of Drupal 8, which means new developments and disruptive changes should now be targeted against the 9.1.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Drupal 9.2.0-alpha1 will be released the week of May 3, 2021, which means new developments and disruptive changes should now be targeted for the 9.3.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.0-rc1 was released on November 26, 2021, which means new developments and disruptive changes should now be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

ranjith_kumar_k_u’s picture

StatusFileSize
new1.17 KB
new535 bytes

Fixed CS error.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.0-alpha1 was released on May 6, 2022, which means new developments and disruptive changes should now be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.5.x-dev » 10.1.x-dev

Drupal 9.5.0-beta2 and Drupal 10.0.0-beta2 were released on September 29, 2022, which means new developments and disruptive changes should now be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

smustgrave’s picture

This issue is being reviewed by the kind folks in Slack, #needs-review-queue-initiative. We are working to keep the size of Needs Review queue [2700+ issues] to around 400 (1 month or less), following Review a patch or merge request as a guide.

Not sure I follow from the issue summary so could we update that with steps to reproduce and proposed solution.

This will also need a unique test. Not sure if editing that one counts as a valid test.

Thanks.

nikhil_110’s picture

StatusFileSize
new1.17 KB

Re-roll patch #16 for 10.x

Version: 10.1.x-dev » 11.x-dev

Drupal core is moving towards using a “main” branch. As an interim step, a new 11.x branch has been opened, as Drupal.org infrastructure cannot currently fully support a branch named main. New developments and disruptive changes should now be targeted for the 11.x branch, which currently accepts only minor-version allowed changes. For more information, see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

smustgrave’s picture

Status: Needs work » Postponed (maintainer needs more info)

For #19

smustgrave’s picture

Status: Postponed (maintainer needs more info) » Closed (outdated)

Since there's been no follow up going to close this one out. Also going to mentioned field_layout is marked to be deprecated and will be moving to contrib in Drupal 12.