[Résolu] Layout being removed when post is being published through Woocommerce
This support ticket is created Il y a 5 années et 5 mois. There's a good chance that you are reading advice that it now obsolete.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
In our workflow, a custom post type called Land Seeker Listing is created through a frontend Toolset Post Form. Payment is charged for the form with Toolset Forms Commerce. The post is created as Pending Review and the order is by default In Progress until an admin marks it as complete. We have the setting chosen so that when an order is complete, it is changed to Published.
When the admins go into the WordPress order and mark it as complete, the post gets published. However, the Layout assigned to it is removed. When I look at the Pending Review listings, they do have the correct layout, so it's the act of publishing them through Woocommerce and Toolset Forms Commerce that is removing the layouts. Any ideas on how to get that working?
I tested this locally and found the same, so I've reported it so that it can be debugged further and a fix found.
I'll let you know when there is some feedback.
In the meantime, I found that the same problem doesn't happen with Content Templates. You could stop using Layouts for this post type and create a Content Template instead and that should work.
If you update the Order from the list of orders (at WooCommerce > Orders) rather than on the individual Order edit screen then the Layout isn't lost. (You can do that via Bulk Actions.)
Thanks for looking into this. The layout for this post type is very complex, so recreating it as a content template isn't a good option. Your second option, completing the order from the Order screen instead of the individual is a bit better. However, it's a better workflow for us to go directly to the order (we get automatic emails with those links when an order comes in). So, if you could please fix this, that would be great. Thanks.
I checked the internal tickets and saw no progress so I mentioned it in today's developer meeting and was promised that they'd look into to see what can be done.
I'll leave this ticket in my assigned queue for now so I'll be reminded to follow up on it if I don't get some news soon.
I haven't forgotten you, but the developer who handles Layouts issues is on vacation till the end of this week and so I'll have nothing to report before next week.
Quick update just to say that I shared again with the developer who said he will look at it this week, so I'll share whatever feedback from him when he does.
Thanks. We're actually in the process of moving the site to new hosting this week to hopefully resolve a different issue we've been having, which keeps us from testing this. When we have it moved, I'll see if this fixes the issue - likely early next week.